Skip to content

test: refactor test_data.py to use only pytest#6440

Merged
aciba90 merged 1 commit into
canonical:mainfrom
chijioke-ibekwe:pytestify-tests
Sep 1, 2025
Merged

test: refactor test_data.py to use only pytest#6440
aciba90 merged 1 commit into
canonical:mainfrom
chijioke-ibekwe:pytestify-tests

Conversation

@chijioke-ibekwe
Copy link
Copy Markdown
Contributor

Proposed Commit Message

test: refactor test_data.py to use only pytest

Remove helpers.TestCase inheritance and replace self.assert methods with bare assert statements. 
This change is a refactor only. Test behavior and coverage remains exactly the same.

Fixes GH-6427

Additional Context

Test Steps

Run the specific unit tests to verify they still pass:

tox -e py3 -- tests/unittests/test_data.py

## Merge type

- [x] Squash merge using "Proposed Commit Message"
- [ ] Rebase and merge unique commits. Requires commit messages per-commit each referencing the pull request number (#<PR_NUM>)

@chijioke-ibekwe
Copy link
Copy Markdown
Contributor Author

Hi @aciba90. Please could you review this?

@aciba90 aciba90 self-assigned this Sep 1, 2025
Copy link
Copy Markdown
Contributor

@aciba90 aciba90 left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

(As this does not fully fix the referenced issue, I am going to modify the commit message to change Fixes GH-xxxx to GH-xxxx, as the former autocloses the issue.)

@aciba90 aciba90 merged commit f123b65 into canonical:main Sep 1, 2025
21 checks passed
DarkPhily pushed a commit to hetznercloud/cloud-init that referenced this pull request Sep 2, 2025
Remove helpers.TestCase inheritance and replace self.assert methods with bare assert statements. 
This change is a refactor only. Test behavior and coverage remains exactly the same.

canonicalGH-6427
blackboxsw pushed a commit to blackboxsw/cloud-init that referenced this pull request Sep 3, 2025
Remove helpers.TestCase inheritance and replace self.assert methods with bare assert statements. 
This change is a refactor only. Test behavior and coverage remains exactly the same.

canonicalGH-6427
blackboxsw pushed a commit to blackboxsw/cloud-init that referenced this pull request Sep 3, 2025
Remove helpers.TestCase inheritance and replace self.assert methods with bare assert statements. 
This change is a refactor only. Test behavior and coverage remains exactly the same.

canonicalGH-6427
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