Skip to content

gh-136438: Make sure test_generated_cases pass with all optimization levels #136594

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

efimov-mikhail
Copy link
Contributor

@efimov-mikhail efimov-mikhail commented Jul 12, 2025

Now tests pass with all combinations of -OO and --without-doc-strings.

Before:

======================================================================
FAIL: test_missing_override_failure (test.test_generated_cases.TestGeneratedAbstractCases.test_missing_override_failure)
----------------------------------------------------------------------
AssertionError: 'case OP: {\n            JitOptRef out;\n [104 chars]   }' != ''
- case OP: {
-             JitOptRef out;
-             out = sym_new_not_null(ctx);
-             stack_pointer[-1] = out;
-             break;
-         }


During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/sikko/projects/cpython/Lib/test/test_generated_cases.py", line 2040, in test_missing_override_failure
    with self.assertRaisesRegex(AssertionError, "All abstract uops"):
         ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: "All abstract uops" does not match "'case OP: {\n            JitOptRef out;\n [104 chars]   }' != ''
- case OP: {
-             JitOptRef out;
-             out = sym_new_not_null(ctx);
-             stack_pointer[-1] = out;
-             break;
-         }
"

@bedevere-app bedevere-app bot mentioned this pull request Jul 12, 2025
8 tasks
@efimov-mikhail efimov-mikhail changed the title gh-136438: Make sure test_generated_cases pass with all optimization levels gh-136438: Make sure test_generated_cases pass with all optimization levels Jul 12, 2025
@StanFromIreland StanFromIreland requested a review from sobolevn July 12, 2025 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants