Skip to content
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

Add Digital Stream Reader tests #494

Merged
merged 4 commits into from
Feb 19, 2024
Merged

Conversation

zhindes
Copy link
Collaborator

@zhindes zhindes commented Feb 14, 2024

What does this Pull Request accomplish?

This ensures we have a test per method for each of the Digital stream readers classes. The existing and new tests all have channel-specific data validation by taking advantage of the behavior of simulated DAQ digital data. This ensures we don't inadvertently swap channels within the Python or underlying C bindings.

Why should this Pull Request be merged?

This will give us confidence that we haven't broken anything as we refactor parts of the Python and driver stack.

What testing has been done?

$ poetry run ni-python-styleguide fix tests && poetry run ni-python-styleguide lint tests && poetry run pytest -rsP -k test___digital
=============================== test session starts ===============================
platform win32 -- Python 3.10.10, pytest-7.4.2, pluggy-1.3.0
rootdir: C:\dev\nidaqmx-python
configfile: pyproject.toml
testpaths: tests
plugins: cov-4.1.0, mock-3.11.1
collected 1641 items / 1585 deselected / 56 selected

tests\component\test_stream_readers.py ..................................... [ 66%]
...................                                                          [100%]

===================================== PASSES ======================================
======================= 56 passed, 1585 deselected in 2.44s =======================

@zhindes zhindes marked this pull request as ready for review February 14, 2024 21:21
Copy link

github-actions bot commented Feb 14, 2024

Test Results

    30 files  ±  0      30 suites  ±0   36m 52s ⏱️ + 1m 25s
 1 668 tests + 56   1 488 ✅ + 56    180 💤 ±0  0 ❌ ±0 
25 650 runs  +840  23 030 ✅ +840  2 620 💤 ±0  0 ❌ ±0 

Results for commit f49fa5d. ± Comparison against base commit 173f46b.

♻️ This comment has been updated with latest results.

tests/component/test_stream_readers.py Outdated Show resolved Hide resolved
tests/component/test_stream_readers.py Outdated Show resolved Hide resolved
tests/component/test_stream_readers.py Outdated Show resolved Hide resolved
tests/component/test_stream_readers.py Outdated Show resolved Hide resolved
tests/component/test_stream_readers.py Outdated Show resolved Hide resolved
tests/component/test_stream_readers.py Outdated Show resolved Hide resolved
tests/component/test_stream_readers.py Show resolved Hide resolved
tests/component/test_stream_readers.py Outdated Show resolved Hide resolved
@zhindes zhindes requested a review from bkeryan February 16, 2024 20:04
tests/component/test_stream_readers.py Outdated Show resolved Hide resolved
@zhindes zhindes enabled auto-merge (squash) February 19, 2024 17:22
@zhindes zhindes merged commit 11b8f56 into master Feb 19, 2024
13 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