Skip to content

Integration tests on DaprClient responses#981

Open
seherv wants to merge 30 commits intodapr:mainfrom
seherv:grpc-tests
Open

Integration tests on DaprClient responses#981
seherv wants to merge 30 commits intodapr:mainfrom
seherv:grpc-tests

Conversation

@seherv
Copy link
Copy Markdown

@seherv seherv commented Apr 15, 2026

Description

Tests the gRPC channel created by DaprClient directly, instead of asserting on the log outputs of the examples like in the PR that removes Mechanical Markdown (#977).
The old log assertions are kept as "documentation tests".

Issue reference

We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.

Please reference the issue this PR will close: #972

Checklist

Please make sure you've completed the relevant tasks for this PR, out of the following list:

  • Code compiles correctly
  • Created/updated tests
  • Extended the documentation

seherv and others added 9 commits April 10, 2026 15:48
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 15, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.53%. Comparing base (bffb749) to head (112cf55).
⚠️ Report is 102 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #981      +/-   ##
==========================================
- Coverage   86.63%   80.53%   -6.10%     
==========================================
  Files          84      136      +52     
  Lines        4473    12678    +8205     
==========================================
+ Hits         3875    10210    +6335     
- Misses        598     2468    +1870     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Contributor

Copilot AI left a 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 migrates example validation away from mechanical-markdown by introducing two pytest suites: (1) stdout-based “documentation” tests that run the examples and assert expected output, and (2) SDK-based integration tests that assert directly on DaprClient responses.

Changes:

  • Replace mechanical-markdown validation with pytest in tox -e examples (stdout assertions).
  • Add tox -e integration suite with a Dapr sidecar test harness and SDK-level assertions.
  • Update CI workflow and contributor docs to reflect the new testing approach.

Reviewed changes

Copilot reviewed 49 out of 49 changed files in this pull request and generated 9 comments.

Show a summary per file
File Description
tox.ini Switch examples validation to pytest; add integration env
.github/workflows/validate_examples.yaml Run both examples + integration in CI
pyproject.toml Add pytest marker registration
examples/validate.sh Remove mechanical-markdown entrypoint
README.md Update developer instructions (examples/integration)
AGENTS.md Update guidance for example validation workflow
examples/AGENTS.md Update example validation documentation
CLAUDE.md Add repo coding/style guidance
examples/conversation/real_llm_providers_example.py Update output text
tests/clients/test_conversation_helpers.py Docstring wording tweak
tests/examples/conftest.py Add DaprRunner helper + example_dir fixture
tests/examples/test_configuration.py Stdout-based example test
tests/examples/test_conversation.py Stdout-based example test
tests/examples/test_crypto.py Stdout-based example test
tests/examples/test_demo_actor.py Stdout-based example test
tests/examples/test_distributed_lock.py Stdout-based example test
tests/examples/test_error_handling.py Stdout-based example test
tests/examples/test_grpc_proxying.py Stdout-based example test
tests/examples/test_invoke_binding.py Stdout-based example test
tests/examples/test_invoke_custom_data.py Stdout-based example test
tests/examples/test_invoke_http.py Stdout-based example test
tests/examples/test_invoke_simple.py Stdout-based example test
tests/examples/test_jobs.py Stdout-based example test
tests/examples/test_langgraph_checkpointer.py Stdout-based example test
tests/examples/test_metadata.py Stdout-based example test
tests/examples/test_pubsub_simple.py Stdout-based example test
tests/examples/test_pubsub_streaming.py Stdout-based example test
tests/examples/test_pubsub_streaming_async.py Stdout-based example test
tests/examples/test_secret_store.py Stdout-based example test
tests/examples/test_state_store.py Stdout-based example test
tests/examples/test_state_store_query.py Stdout-based example test
tests/examples/test_w3c_tracing.py Stdout-based example test
tests/examples/test_workflow.py Stdout-based example test
tests/integration/conftest.py Add DaprTestEnvironment harness for SDK tests
tests/integration/secrets.json Local secret store test data
tests/integration/test_configuration.py SDK-based configuration tests
tests/integration/test_distributed_lock.py SDK-based lock tests
tests/integration/test_invoke.py SDK-based invocation tests
tests/integration/test_metadata.py SDK-based metadata tests
tests/integration/test_pubsub.py SDK-based pub/sub delivery tests
tests/integration/test_secret_store.py SDK-based secret store tests
tests/integration/test_state_store.py SDK-based state store tests
tests/integration/apps/invoke_receiver.py gRPC app for invoke tests
tests/integration/apps/pubsub_subscriber.py Subscriber app persisting received events
tests/integration/components/configurationstore.yaml Redis configuration component
tests/integration/components/localsecretstore.yaml Local-file secret store component
tests/integration/components/lockstore.yaml Redis lock component
tests/integration/components/pubsub.yaml Redis pubsub component
tests/integration/components/statestore.yaml Redis state component

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread README.md Outdated
Comment thread examples/AGENTS.md Outdated
Comment thread AGENTS.md Outdated
Comment thread tests/integration/conftest.py
Comment thread tests/examples/test_configuration.py
Comment thread tests/clients/test_conversation_helpers.py Outdated
Comment thread examples/AGENTS.md Outdated
Comment thread tests/integration/test_configuration.py
Comment thread examples/conversation/real_llm_providers_example.py Outdated
seherv added 2 commits April 16, 2026 11:46
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 48 out of 48 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/integration/test_configuration.py
Comment thread tests/integration/test_pubsub.py Outdated
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 48 out of 48 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tox.ini
Comment thread tests/integration/conftest.py
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 48 out of 48 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread README.md Outdated
Comment thread tox.ini
Comment thread tests/integration/conftest.py
Comment thread tests/integration/conftest.py Outdated
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 48 out of 48 changed files in this pull request and generated 8 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/integration/AGENTS.md Outdated
Comment thread tox.ini Outdated
Comment thread tox.ini Outdated
Comment thread tox.ini Outdated
Comment thread tox.ini Outdated
Comment thread tests/integration/conftest.py Outdated
Comment thread tests/examples/test_langgraph_checkpointer.py
Comment thread README.md Outdated
cmd in test_langgraph_checkpointer.py

Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 48 out of 48 changed files in this pull request and generated 3 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/examples/test_langgraph_checkpointer.py Outdated
Comment thread tests/examples/test_workflow.py Outdated
Comment thread tests/examples/test_langgraph_checkpointer.py
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
seherv and others added 13 commits April 20, 2026 13:54
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 49 out of 49 changed files in this pull request and generated 3 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tox.ini Outdated
Comment thread tox.ini Outdated
Comment thread tox.ini Outdated
seherv added 2 commits April 20, 2026 14:05
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
@seherv seherv marked this pull request as ready for review April 20, 2026 12:06
@seherv seherv requested review from a team as code owners April 20, 2026 12:06
Signed-off-by: Sergio Herrera <627709+seherv@users.noreply.github.com>
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.

(parent) refactor: mv mechanical markdown tests to pytest native

3 participants