Skip to content

Conversation

@maximyurchuk
Copy link
Collaborator

@maximyurchuk maximyurchuk commented Jun 11, 2025

Do not use setup_class -- it is a bad practice

@maximyurchuk maximyurchuk marked this pull request as ready for review June 11, 2025 13:16
@maximyurchuk maximyurchuk requested a review from Copilot June 11, 2025 13:16
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the test setup by replacing the legacy class-level setup and teardown methods with a pytest fixture using autouse, aligning the tests with current best practices.

  • Replaced the @classmethod-based setup and teardown with a pytest fixture that uses yield for teardown.
  • Removed the separate teardown_class method to streamline setup and cleanup.
Comments suppressed due to low confidence (1)

ydb/tests/example/test_example.py:17

  • [nitpick] Consider renaming the fixture from 'setup_class' to a name that better reflects its usage as a pytest fixture (e.g., 'cluster_setup') to avoid confusion with the legacy setup_class pattern.
@pytest.fixture(autouse=True)

@github-actions
Copy link

github-actions bot commented Jun 11, 2025

🟢 2025-06-11 13:20:11 UTC The validation of the Pull Request description is successful.

@github-actions
Copy link

github-actions bot commented Jun 11, 2025

2025-06-11 13:27:18 UTC Pre-commit check linux-x86_64-release-asan for 5424a98 has started.
2025-06-11 13:27:44 UTC Artifacts will be uploaded here
2025-06-11 13:30:55 UTC ya make is running...
🟢 2025-06-11 13:33:13 UTC Tests successful.

Test history | Ya make output | Test bloat

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
7 6 0 0 1 0

🟢 2025-06-11 13:33:20 UTC Build successful.
🟡 2025-06-11 13:33:34 UTC ydbd size 3.9 GiB changed* by +104.3 KiB, which is >= 100.0 KiB vs main: Warning

ydbd size dash main: 8e0f901 merge: 5424a98 diff diff %
ydbd size 4 167 775 264 Bytes 4 167 882 080 Bytes +104.3 KiB +0.003%
ydbd stripped size 1 445 699 288 Bytes 1 445 739 960 Bytes +39.7 KiB +0.003%

*please be aware that the difference is based on comparing your commit and the last completed build from the post-commit, check comparation

@github-actions
Copy link

github-actions bot commented Jun 11, 2025

2025-06-11 13:27:45 UTC Pre-commit check linux-x86_64-relwithdebinfo for 5424a98 has started.
2025-06-11 13:28:00 UTC Artifacts will be uploaded here
2025-06-11 13:31:08 UTC ya make is running...
🟢 2025-06-11 13:32:51 UTC Tests successful.

Test history | Ya make output | Test bloat

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
9 8 0 0 1 0

🟢 2025-06-11 13:32:58 UTC Build successful.
🟢 2025-06-11 13:33:08 UTC ydbd size 2.2 GiB changed* by +40.2 KiB, which is < 100.0 KiB vs main: OK

ydbd size dash main: cac7377 merge: 5424a98 diff diff %
ydbd size 2 369 797 552 Bytes 2 369 838 720 Bytes +40.2 KiB +0.002%
ydbd stripped size 497 038 888 Bytes 497 045 320 Bytes +6.3 KiB +0.001%

*please be aware that the difference is based on comparing your commit and the last completed build from the post-commit, check comparation

@maximyurchuk maximyurchuk merged commit 516a269 into ydb-platform:main Jun 11, 2025
12 checks passed
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