merge stabilization/2106 into development
Signed-off-by: hultonha <hultonha@amazon.co.uk>
This commit is contained in:
@@ -9,6 +9,7 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS)
|
||||
ly_add_pytest(
|
||||
NAME AutomatedTesting::NvClothTests_Main
|
||||
TEST_SUITE main
|
||||
TEST_REQUIRES gpu
|
||||
TEST_SERIAL
|
||||
PATH ${CMAKE_CURRENT_LIST_DIR}/TestSuite_Active.py
|
||||
TIMEOUT 1500
|
||||
|
||||
@@ -20,10 +20,13 @@ from base import TestAutomationBase
|
||||
@pytest.mark.parametrize("project", ["AutomatedTesting"])
|
||||
class TestAutomation(TestAutomationBase):
|
||||
|
||||
use_null_renderer = False # Use default renderer (needs gpu)
|
||||
extra_cmdline_args = []
|
||||
|
||||
def test_C18977329_NvCloth_AddClothSimulationToMesh(self, request, workspace, editor, launcher_platform):
|
||||
from . import C18977329_NvCloth_AddClothSimulationToMesh as test_module
|
||||
self._run_test(request, workspace, editor, test_module)
|
||||
self._run_test(request, workspace, editor, test_module, self.extra_cmdline_args, self.use_null_renderer)
|
||||
|
||||
def test_C18977330_NvCloth_AddClothSimulationToActor(self, request, workspace, editor, launcher_platform):
|
||||
from . import C18977330_NvCloth_AddClothSimulationToActor as test_module
|
||||
self._run_test(request, workspace, editor, test_module)
|
||||
self._run_test(request, workspace, editor, test_module, self.extra_cmdline_args, self.use_null_renderer)
|
||||
|
||||
@@ -51,7 +51,7 @@ class TestAutomationBase:
|
||||
cls._kill_ly_processes()
|
||||
|
||||
|
||||
def _run_test(self, request, workspace, editor, testcase_module, extra_cmdline_args=[]):
|
||||
def _run_test(self, request, workspace, editor, testcase_module, extra_cmdline_args=[], use_null_renderer=True):
|
||||
test_starttime = time.time()
|
||||
self.logger = logging.getLogger(__name__)
|
||||
errors = []
|
||||
@@ -89,7 +89,10 @@ class TestAutomationBase:
|
||||
editor_starttime = time.time()
|
||||
self.logger.debug("Running automated test")
|
||||
testcase_module_filepath = self._get_testcase_module_filepath(testcase_module)
|
||||
pycmd = ["--runpythontest", testcase_module_filepath, "-BatchMode", "-autotest_mode", "-rhi=null", f"-pythontestcase={request.node.originalname}"] + extra_cmdline_args
|
||||
pycmd = ["--runpythontest", testcase_module_filepath, "-BatchMode", "-autotest_mode", f"-pythontestcase={request.node.originalname}"]
|
||||
if use_null_renderer:
|
||||
pycmd += ["-rhi=null"]
|
||||
pycmd += extra_cmdline_args
|
||||
editor.args.extend(pycmd) # args are added to the WinLauncher start command
|
||||
editor.start(backupFiles = False, launch_ap = False)
|
||||
try:
|
||||
|
||||
@@ -58,8 +58,11 @@ class TestFileMenuDefaultNewOpen:
|
||||
sc_main = sc.findChild(QtWidgets.QMainWindow)
|
||||
sc_tabs = sc_main.findChild(QtWidgets.QTabWidget, "ScriptCanvasTabs")
|
||||
|
||||
# 3) Trigger File->New action
|
||||
# wait for the intial tab count
|
||||
general.idle_wait(GENERAL_WAIT)
|
||||
initial_tabs_count = sc_tabs.count()
|
||||
|
||||
# 3) Trigger File->New action
|
||||
action = pyside_utils.find_child_by_pattern(
|
||||
sc_main, {"objectName": "action_New_Script", "type": QtWidgets.QAction}
|
||||
)
|
||||
|
||||
@@ -51,17 +51,4 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS)
|
||||
AutomatedTesting.GameLauncher
|
||||
AutomatedTesting.Assets
|
||||
)
|
||||
|
||||
ly_add_pytest(
|
||||
NAME AutomatedTesting::GameLauncherWithGPU
|
||||
TEST_REQUIRES gpu
|
||||
PATH ${CMAKE_CURRENT_LIST_DIR}/test_GameLauncher_EnterExitGameMode_Works.py
|
||||
TIMEOUT 100
|
||||
RUNTIME_DEPENDENCIES
|
||||
AZ::AssetProcessor
|
||||
AZ::PythonBindingsExample
|
||||
Legacy::Editor
|
||||
AutomatedTesting.GameLauncher
|
||||
AutomatedTesting.Assets
|
||||
)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user