Skip to content

ci: add doc test warning check to CI pipeline#2

Open
twenty-tools wants to merge 1 commit intomasterfrom
ci/doc-warnings
Open

ci: add doc test warning check to CI pipeline#2
twenty-tools wants to merge 1 commit intomasterfrom
ci/doc-warnings

Conversation

@twenty-tools
Copy link

@twenty-tools twenty-tools commented Mar 15, 2026

Adds a new CI job that runs doc tests with warnings denied, catching deprecated API usage, unused variables, and other warnings in doc comment code examples.

The existing check-rustdoc-links job catches broken intra-doc links and rustdoc-level warnings, but does not compile doc examples. This new job fills that gap by running cargo test --doc with RUSTDOCFLAGS=-D warnings.

Addresses libp2p#3282.


Summary by cubic

Adds a CI job that runs doc tests with warnings denied to catch deprecated APIs and other warnings in doc examples. Complements the existing rustdoc links check by actually compiling the examples.

  • New Features
    • Runs cargo test --doc --workspace --all-features with RUSTDOCFLAGS="-D warnings" to fail on any doc test warnings.

Written for commit 7a534e1. Summary will update on new commits.

Adds a new CI job that runs cargo test --doc with RUSTDOCFLAGS=-D warnings, catching deprecated API usage, unused variables, and other warnings in doc comment code examples. Addresses libp2p#3282.
Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 1 file

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