Added an assert to verify AP and AP Batch close on teardown. (#5891)
* Added an assert to verify AP and AP Batch close on teardown. Signed-off-by: Rosario Cox <lesaelr@amazon.com> * Removed ".exe" from assert to ensure it works on any platform Fixed missing set of parenthesis in the assert Added "AssetBuilder" to the assert to ensure assetbuilders have closed correctly Signed-off-by: Rosario Cox <lesaelr@amazon.com> * Moving the helper function from asset_processor_fixture to asset_processor_utils. Changed individual process_utils calls into a single call with a list. Signed-off-by: Rosario Cox <lesaelr@amazon.com> * Added the missing references. Signed-off-by: Rosario Cox <lesaelr@amazon.com>
This commit is contained in:
@@ -15,6 +15,7 @@ import logging
|
||||
|
||||
# Import LyTestTools
|
||||
import ly_test_tools.o3de.asset_processor as asset_processor_commands
|
||||
import ly_test_tools.o3de.asset_processor_utils
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
@@ -36,5 +37,8 @@ def asset_processor(request: pytest.fixture, workspace: pytest.fixture) -> asset
|
||||
ap.stop()
|
||||
|
||||
request.addfinalizer(teardown)
|
||||
for n in ly_test_tools.o3de.asset_processor_utils.processList:
|
||||
assert not ly_test_tools.o3de.asset_processor_utils.check_ap_running(n), f"{n} process did not shutdown correctly."
|
||||
|
||||
|
||||
return ap
|
||||
|
||||
Reference in New Issue
Block a user