From 0ae25fe7e7d560c07a53f0df29b328246b1a2e2f Mon Sep 17 00:00:00 2001 From: jromnoa Date: Fri, 27 Aug 2021 20:35:11 -0700 Subject: [PATCH] add extra timeout value as well as some extra time.sleep() calls in an attempt to fix the test (seems race condition related) Signed-off-by: jromnoa --- .../atom_hydra_scripts/hydra_AtomMaterialEditor_BasicTests.py | 2 ++ .../Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/AutomatedTesting/Gem/PythonTests/atom_renderer/atom_hydra_scripts/hydra_AtomMaterialEditor_BasicTests.py b/AutomatedTesting/Gem/PythonTests/atom_renderer/atom_hydra_scripts/hydra_AtomMaterialEditor_BasicTests.py index b3c51ca912..130482cb99 100644 --- a/AutomatedTesting/Gem/PythonTests/atom_renderer/atom_hydra_scripts/hydra_AtomMaterialEditor_BasicTests.py +++ b/AutomatedTesting/Gem/PythonTests/atom_renderer/atom_hydra_scripts/hydra_AtomMaterialEditor_BasicTests.py @@ -67,6 +67,7 @@ def run(): material_editor.save_document_as_child(document_id, target_path) material_editor.wait_for_condition(lambda: os.path.exists(target_path), 2.0) print(f"New asset created: {os.path.exists(target_path)}") + time.sleep(2.0) # Verify if the newly created document is open new_document_id = material_editor.open_material(target_path) @@ -101,6 +102,7 @@ def run(): expected_color = math.Color(0.25, 0.25, 0.25, 1.0) material_editor.set_property(document_id, property_name, expected_color) material_editor.save_document(document_id) + time.sleep(2.0) # 7) Test Case: Saving as a New Material # Assign new color to the material file and save the document as copy diff --git a/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py b/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py index bb7a16ad6b..646c20a84f 100644 --- a/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py +++ b/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py @@ -299,7 +299,7 @@ class TestMaterialEditorBasicTests(object): generic_launcher, "hydra_AtomMaterialEditor_BasicTests.py", run_python="--runpython", - timeout=80, + timeout=EDITOR_TIMEOUT, expected_lines=expected_lines, unexpected_lines=unexpected_lines, halt_on_unexpected=True,