Skip to content

bpo-45229: Make ElementTree tests discoverable #108859

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

Merged
merged 1 commit into from
Sep 4, 2023

Conversation

serhiy-storchaka
Copy link
Member

@serhiy-storchaka serhiy-storchaka commented Sep 4, 2023

@vstinner
Copy link
Member

vstinner commented Sep 4, 2023

Without the PR, main branch:

$ ./python -m test -v test_xml_etree_c
(...)
Warning -- test_xml_etree_c test runner returned None: <function test_main at 0x7f94a1758650>

Total duration: 2.3 sec
Total tests: run=0
Total test files: run=1/1

With the PR:

$ ./python -m test -v test_xml_etree_c
(...)
Total tests: run=208 skipped=6
Total test files: run=1/1

regrtest is able to count the number of tests, nice!

I counted manually the number of tests in the main branch (count the number of lines in short), and I also see 208 tests! I only see 5 skipped tests, but here 6 are announced. Aha, interesting!

@serhiy-storchaka
Copy link
Member Author

I only see 5 skipped tests, but here 6 are announced.

It counts skipped NoAcceleratorTest. In the old code it was not added to the explicit list of test classes.

@serhiy-storchaka serhiy-storchaka merged commit 074ac1f into python:main Sep 4, 2023
@miss-islington
Copy link
Contributor

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.11, 3.12.
🐍🍒⛏🤖

@serhiy-storchaka serhiy-storchaka deleted the test-etree-discover branch September 4, 2023 10:04
@miss-islington
Copy link
Contributor

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.12 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker 074ac1f72e392a576516639f650bac0519d1cb52 3.12

@miss-islington
Copy link
Contributor

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.11 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker 074ac1f72e392a576516639f650bac0519d1cb52 3.11

serhiy-storchaka added a commit to serhiy-storchaka/cpython that referenced this pull request Sep 4, 2023
(cherry picked from commit 074ac1f)

Co-authored-by: Serhiy Storchaka <[email protected]>
@bedevere-bot
Copy link

GH-108873 is a backport of this pull request to the 3.12 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.12 only security fixes label Sep 4, 2023
serhiy-storchaka added a commit to serhiy-storchaka/cpython that referenced this pull request Sep 4, 2023
(cherry picked from commit 074ac1f)

Co-authored-by: Serhiy Storchaka <[email protected]>
@bedevere-bot
Copy link

GH-108874 is a backport of this pull request to the 3.11 branch.

@vstinner
Copy link
Member

vstinner commented Sep 4, 2023

It counts skipped NoAcceleratorTest. In the old code it was not added to the explicit list of test classes.

Minor but nice improvement to take :-)

Yhg1s pushed a commit that referenced this pull request Sep 5, 2023
…08873)

[3.12] bpo-45229: Make ElementTree tests discoverable (GH-108859).
(cherry picked from commit 074ac1f)
@serhiy-storchaka serhiy-storchaka removed their assignment Sep 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip news tests Tests in the Lib/test dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants