From a7b3265b0bede021983dde9452d37249d218c9a5 Mon Sep 17 00:00:00 2001 From: Dan McGarry Date: Wed, 25 May 2022 12:19:02 -0700 Subject: [PATCH] Force Y-up axis for image compare tests Pixar uses Z-up by default. This preference is set in userSetup.mel and in many user's saved preferences. This change ensures image compare tests pass even when run in this environment. --- .../vp2RenderDelegate/testVP2RenderDelegateConsolidation.py | 4 ++-- .../vp2RenderDelegate/testVP2RenderDelegateDuplicateProxy.py | 4 ++-- .../testVP2RenderDelegateInteractiveWorkflows.py | 4 ++++ .../testVP2RenderDelegatePerInstanceInheritedData.py | 4 ++-- 4 files changed, 10 insertions(+), 6 deletions(-) diff --git a/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateConsolidation.py b/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateConsolidation.py index 55144b39ab..0ec6ba96d7 100644 --- a/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateConsolidation.py +++ b/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateConsolidation.py @@ -40,9 +40,9 @@ class testVP2RenderDelegateConsolidation(imageUtils.ImageDiffingTestCase): @classmethod def setUpClass(cls): - # The test USD data is authored Z-up, so make sure Maya is configured + # The baselines assume Y-up, so make sure Maya is configured # that way too. - # cmds.upAxis(axis='z') + cmds.upAxis(axis='y') inputPath = fixturesUtils.setUpClass(__file__, initializeStandalone=False, loadPlugin=False) diff --git a/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateDuplicateProxy.py b/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateDuplicateProxy.py index c7db41adb7..08f0511863 100644 --- a/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateDuplicateProxy.py +++ b/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateDuplicateProxy.py @@ -39,9 +39,9 @@ class testVP2RenderDelegateDuplicateProxy(imageUtils.ImageDiffingTestCase): @classmethod def setUpClass(cls): - # The test USD data is authored Z-up, so make sure Maya is configured + # The baselines assume Y-up, so make sure Maya is configured # that way too. - # cmds.upAxis(axis='z') + cmds.upAxis(axis='y') inputPath = fixturesUtils.setUpClass(__file__, initializeStandalone=False, loadPlugin=False) diff --git a/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateInteractiveWorkflows.py b/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateInteractiveWorkflows.py index 8621a5a75a..671b8cc66c 100644 --- a/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateInteractiveWorkflows.py +++ b/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegateInteractiveWorkflows.py @@ -44,6 +44,10 @@ class testVP2RenderDelegateInteractiveWorkflows(imageUtils.ImageDiffingTestCase) @classmethod def setUpClass(cls): + # The baselines assume Y-up, so make sure Maya is configured + # that way too. + cmds.upAxis(axis='y') + inputPath = fixturesUtils.setUpClass(__file__, initializeStandalone=False, loadPlugin=False) diff --git a/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegatePerInstanceInheritedData.py b/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegatePerInstanceInheritedData.py index f68682730d..10aadf5797 100644 --- a/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegatePerInstanceInheritedData.py +++ b/test/lib/mayaUsd/render/vp2RenderDelegate/testVP2RenderDelegatePerInstanceInheritedData.py @@ -43,9 +43,9 @@ class testVP2RenderDelegatePerInstanceInheritedData(imageUtils.ImageDiffingTestC @classmethod def setUpClass(cls): - # The test USD data is authored Z-up, so make sure Maya is configured + # The baselines assume Y-up, so make sure Maya is configured # that way too. - # cmds.upAxis(axis='z') + cmds.upAxis(axis='y') inputPath = fixturesUtils.setUpClass(__file__, initializeStandalone=False, loadPlugin=False)