Skip to content

test: convert test_util.py from unit test to pytest#6536

Merged
blackboxsw merged 1 commit into
canonical:mainfrom
csemanish12:pytest-util-migration
Oct 28, 2025
Merged

test: convert test_util.py from unit test to pytest#6536
blackboxsw merged 1 commit into
canonical:mainfrom
csemanish12:pytest-util-migration

Conversation

@csemanish12
Copy link
Copy Markdown
Contributor

Refactored tests/unittests/test_util.py to use pytest instead of unittest.TestCase as part of the pytest migration effort.

  • Removed TestCase inheritance
  • Refactored tests to use pytest tmp_path fixture for temp directory handling
  • Maintained all original test functionality

Related: #6427

Refactored tests/unittests/test_util.py to use pytest instead of unittest.TestCase as part of the pytest migration effort.
  - Removed TestCase inheritance
  - Refactored tests to use pytest tmp_path fixture for temp directory handling
  - Maintained all original test functionality

  Related: canonical#6427
Copy link
Copy Markdown
Collaborator

@blackboxsw blackboxsw left a comment

Choose a reason for hiding this comment

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

LGTM! Thank you for the contibution

@blackboxsw blackboxsw merged commit 9e4c9d2 into canonical:main Oct 28, 2025
21 checks passed
blackboxsw pushed a commit to blackboxsw/cloud-init that referenced this pull request Dec 12, 2025
Refactored tests/unittests/test_util.py to use pytest instead
of unittest.TestCase as part of the pytest migration effort.

- Removed TestCase inheritance
- Refactored tests to use pytest tmp_path fixture for temp
  directory handling
- Maintained all original test functionality

Related: canonical#6427
holmanb pushed a commit that referenced this pull request Dec 18, 2025
Refactored tests/unittests/test_util.py to use pytest instead
of unittest.TestCase as part of the pytest migration effort.

- Removed TestCase inheritance
- Refactored tests to use pytest tmp_path fixture for temp
  directory handling
- Maintained all original test functionality

Related: #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