test: raise coverage with expanded unit tests and offline nox workflow#66
Open
test: raise coverage with expanded unit tests and offline nox workflow#66
Conversation
d0633ba to
d25bea4
Compare
Improve test coverage to at least 90% Automated by loop.
d25bea4 to
0321e34
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR improves test coverage for Issue #21 by strengthening unit tests around
pytest_libiio.coverageandpytest_libiio.tools, and by updating the Nox workflow to run a deterministic offline test subset.Changes
tests/test_coverage.py:mocker.patch.object(...)usage withunittest.mock.MagicMock+monkeypatch.pytest-mockfixture.tests/test_tools.py:mocker-based patching withmonkeypatch.setattr(...)lambdas.Pathimport.noxfile.py:testssession into an offline, targeted unit session (python=False,name="tests").tests/test_coverage.pyandtests/test_tools.py.PYTEST_DISABLE_PLUGIN_AUTOLOAD=1for reproducible, isolated runs.checksession for Ruff lint/format validation.Impact
Closes https://github.com/tfcollins/tbot/issues/22