Skip to content

test: add comprehensive Data Store V2 acceptance coverage - #211

Open
priya-ni wants to merge 3 commits into
mainfrom
users/pgopal/add-v2-acceptance-tests
Open

priya-ni wants to merge 3 commits into
mainfrom
users/pgopal/add-v2-acceptance-tests

Conversation

@priya-ni

Copy link
Copy Markdown
Contributor

What does this Pull Request accomplish?

Adds acceptance coverage for Data Store V2 resource creation, measurement values and limits, condition lifecycle, metadata expansion, queries, pagination, and resource mutations. Documents how to run the V2 suite separately from V1.

Why should this Pull Request be merged?

Provides broader end-to-end coverage for V2 workflows and helps catch regressions in service interactions. V2 does not currently expose batch condition publishing or standalone condition queries, so those V1 cases have no V2 equivalent.

What testing has been done?

  • pytest -q tests/unit: 485 passed
  • pytest --collect-only -q tests/acceptance_v2: 39 tests collected
  • Black formatting check passed
  • Mypy passed

The service-backed V2 acceptance tests were not run; they require a V2 DataStore service and publish data.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Metadata expansion tests reject correct results because they compare against inputs lacking assigned IDs, while pagination tests can pass even when page-size limits are ignored.

2 open issues
What changed in this PR

Adds a separate Data Store V2 acceptance suite to broaden end-to-end coverage of the Python client without changing production code.

Changes:

  • Covers measurement values, limits, batch creation, condition lifecycle, and metadata expansion.
  • Adds resource filtering, pagination, update, and deletion tests.
  • Documents running V2 acceptance tests separately from V1.

The service-backed V2 tests have not yet been run, as noted in the PR description.

File Description
tests/​acceptance_v2/​test_resource_lifecycle.py Tests batch creation, updates, and deletion.
tests/​acceptance_v2/​test_query_resources.py Tests resource filtering by ID and name.
tests/​acceptance_v2/​test_query_pagination.py Tests step and test-result pagination.
tests/​acceptance_v2/​test_publish_with_metadata.py Tests metadata references, expansion, extensions, and waveform readback.
tests/​acceptance_v2/​test_publish_measurement_batch_and_read_data.py Tests vectors and batch measurement readback.
tests/​acceptance_v2/​test_publish_measurement_and_read_data.py Tests round trips for supported measurement value types.
tests/​acceptance_v2/​test_publish_condition_and_read_data.py Tests condition values, replacement, and removal.
tests/​acceptance_v2/​test_measurement_value_options.py Tests reading measurement values and limits.
tests/​acceptance_v2/​test_data_store.py Tests core V2 fields and measurement pagination.
tests/​acceptance_v2/​conftest.py Provides the shared service-context fixture.
tests/​acceptance_v2/​_utils.py Adds a test-result and step creation helper.
tests/​acceptance_v2/​__init__.py Defines the V2 acceptance-test package.
CONTRIBUTING.md Documents the V2 test command and condition API exclusions.

Review effort: Balanced

priya-ni and others added 2 commits November 24, 2026 13:36
Update assertions to retrieve items from metadata store.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@priya-ni
priya-ni marked this pull request as ready for review November 24, 2026 08:10
@priya-ni
priya-ni requested a review from a team as a code owner November 24, 2026 08:10

This branch has not been deployed

No deployments
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