Skip to content

convert bare assert statements in TestCase methods to self.assertEqual#3965

Open
pmolodo wants to merge 1 commit intoPixarAnimationStudios:devfrom
pmolodo:pr/convert_assert_statements_to_TestCase.assertEqual_simple
Open

convert bare assert statements in TestCase methods to self.assertEqual#3965
pmolodo wants to merge 1 commit intoPixarAnimationStudios:devfrom
pmolodo:pr/convert_assert_statements_to_TestCase.assertEqual_simple

Conversation

@pmolodo
Copy link
Contributor

@pmolodo pmolodo commented Jan 28, 2026

NOTE for reviewing:

Since these changes were automatically generated, I recommend reviewing the libCST script used to generate them, linked below, and a sampling of the changes.

Description of Change(s)

...where appropriate, and the comparison is simple.

This makes errors report more useful information - particularly helpful for infrequent or hard-to-reproduce failures.

These changes were automatically generated using a libCST script to parse source code and make changes in a syntax-safe way. This is the exact script used to make these changes:

https://github.com/pmolodo/convert_assert_statements/blob/f2a096191eef3d61fd7e808feeab6b5111a57042/convert_TestCase_assert_statements_to_assert_methods.py

Link to proposal (if applicable)

Fixes Issue(s)

Checklist

*Technically, all unit tests did not pass - but the same set failed that also failed on an unmodified pixar/dev branch. These were the failures (all Usdview / UsdImagingGL):

99% tests passed, 14 tests failed out of 1619

Total Test time (real) = 127.82 sec

The following tests FAILED:
	1508 - testUsdImagingGLTextureResync (Failed)
	1529 - testUsdImagingGLMaterialXLocalCustomNodes_simpleNodes (Failed)
	1598 - testUsdviewLights_yup (Failed)
	1599 - testUsdviewSceneLights (Failed)
	1600 - testUsdviewSceneLights_Delegate (Failed)
	1601 - testUsdviewSceneMaterials (Failed)
	1603 - testUsdviewLightVisibility_varying (Failed)
	1612 - testUsdviewMaterialEdits (Failed)
	1615 - testUsdviewCPUSkinning (Failed)
	1616 - testUsdviewGPUSkinning (Failed)
	1618 - testUsdviewPrimvarEdits (Failed)
	1619 - testUsdviewOIT (Failed)
	1620 - testUsdviewAdditive (Failed)
	1623 - testUsdviewPointInstancerVariant (Failed)

...where appropriate, and the comparison is simple.

This makes errors report more useful information - particularly helpful
for infrequent or hard-to-reproduce failures.

These changes were automatically generated using a libCST script to
parse source code and make changes in a syntax-safe way.  This is the
exact script used to make these changes:

https://github.com/pmolodo/convert_assert_statements/blob/f2a096191eef3d61fd7e808feeab6b5111a57042/convert_TestCase_assert_statements_to_assert_methods.py
@pmolodo pmolodo force-pushed the pr/convert_assert_statements_to_TestCase.assertEqual_simple branch from 86d5c58 to 853ddbc Compare January 28, 2026 07:15
@jesschimein
Copy link
Collaborator

Filed as internal issue #USD-11845

(This is an automated message. See here for more information.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants