-
Couldn't load subscription status.
- Fork 0
Implement Task AB#3095678 - Define Measurement Script API #2
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
Conversation
Test Results10 files ± 0 10 suites ±0 5s ⏱️ +4s Results for commit f4d4a52. ± Comparison against base commit 258525c. This pull request removes 1 and adds 3 tests. Note that renamed tests count towards both.♻️ This comment has been updated with latest results. |
There was a problem hiding this 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 introduces the initial NiPanel interface as part of the Measurement Script API, laying the groundwork for future implementation of connect, disconnect, set_value, and get_value methods. Key changes include:
- Defining the NiPanel class with context management support.
- Adding basic unit tests for constructing, invoking, and using NiPanel via both direct calls and a with statement.
- Cleaning up legacy placeholder tests.
Reviewed Changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| tests/unit/test_placeholder.py | Removed placeholder test in favor of a focused test suite. |
| tests/unit/test_nipanel.py | Added unit tests for the NiPanel functionality. |
| tests/init.py | Added an init file with module documentation for tests. |
| src/nipanel/nipanel.py | Introduced the NiPanel class with API stubs and context handling. |
| src/nipanel/init.py | Updated module exports for the NiPanel class. |
Files not reviewed (1)
- .vscode/settings.json: Language not supported
… accessors for that and panel_uri.
What does this Pull Request accomplish?
This PR defines the NiPanel interface class, with the methods that the user's measurement script will call.
Why should this Pull Request be merged?
This is the first step towards implementing the PythonPanel client API. Note that implementing the methods connect(), disconnect(), set_value() and get_value() will be done in subsequent PRs.
What testing has been done?
Two basic unit tests were added. One test calls each of the four methods directly, and the other test uses a with statement to call connect() and disconnect() automatically.