Skip to content

Integration and api tests#2278

Open
Tehforsch wants to merge 43 commits into
mainfrom
integration-and-api-tests
Open

Integration and api tests#2278
Tehforsch wants to merge 43 commits into
mainfrom
integration-and-api-tests

Conversation

@Tehforsch

@Tehforsch Tehforsch commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

TODO: Fix the test which currently asserts on plugin_feed_info.inc being returned by GET /vts

Rough structure:

  • Adds openvasd integration tests add src/openvasd/api_tests/.
  • They replace the hurl tests, so hurl tests are deleted
  • The existing compose setup has been slightly refactored to contain a base.yaml which spawns all the necessary processes and a separate openvasd.yaml which just spawns openvasd. The tests then take place by only spawning base.yaml and then inserting rust-tests.yaml instead, which runs the unit test in a container similar to openvasd.
  • The unit tests work by spawning individual openvasd instances which listen at different ports and sending API requests to those instances.
  • Tests that use openvas share a single central openvas instance. To make sure things work smoothly, they contend for a shared lock so that they ever run in serial. After each test, the redis cache is cleared.

@github-actions

github-actions Bot commented Jul 13, 2026

Copy link
Copy Markdown

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Snapshot Warnings

⚠️: No snapshots were found for the head SHA 912e481.
Ensure that dependencies are being submitted on PR branches and consider enabling retry-on-snapshot-warnings. See the documentation for more information and troubleshooting advice.

OpenSSF Scorecard

PackageVersionScoreDetails
cargo/pest 2.8.7 🟢 5.8
Details
CheckScoreReason
Security-Policy🟢 10security policy file detected
Dangerous-Workflow🟢 10no dangerous workflow patterns detected
Packaging⚠️ -1packaging workflow not detected
Code-Review🟢 5Found 15/27 approved changesets -- score normalized to 5
CII-Best-Practices⚠️ 0no effort to earn an OpenSSF best practices badge detected
Maintained🟢 57 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 5
Binary-Artifacts🟢 10no binaries found in the repo
Token-Permissions⚠️ 0detected GitHub workflow tokens with excessive permissions
Pinned-Dependencies⚠️ 0dependency not pinned by hash detected -- score normalized to 0
Fuzzing🟢 10project is fuzzed
License🟢 10license file detected
Branch-Protection⚠️ -1internal error: error during branchesHandler.setup: internal error: some github tokens can't read classic branch protection rules: https://github.com/ossf/scorecard-action/blob/main/docs/authentication/fine-grained-auth-token.md
Signed-Releases⚠️ -1no releases found
SAST⚠️ 0SAST tool is not run on all commits -- score normalized to 0
cargo/pest_derive 2.8.7 🟢 5.8
Details
CheckScoreReason
Security-Policy🟢 10security policy file detected
Dangerous-Workflow🟢 10no dangerous workflow patterns detected
Packaging⚠️ -1packaging workflow not detected
Code-Review🟢 5Found 15/27 approved changesets -- score normalized to 5
CII-Best-Practices⚠️ 0no effort to earn an OpenSSF best practices badge detected
Maintained🟢 57 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 5
Binary-Artifacts🟢 10no binaries found in the repo
Token-Permissions⚠️ 0detected GitHub workflow tokens with excessive permissions
Pinned-Dependencies⚠️ 0dependency not pinned by hash detected -- score normalized to 0
Fuzzing🟢 10project is fuzzed
License🟢 10license file detected
Branch-Protection⚠️ -1internal error: error during branchesHandler.setup: internal error: some github tokens can't read classic branch protection rules: https://github.com/ossf/scorecard-action/blob/main/docs/authentication/fine-grained-auth-token.md
Signed-Releases⚠️ -1no releases found
SAST⚠️ 0SAST tool is not run on all commits -- score normalized to 0
cargo/pest_generator 2.8.7 🟢 5.8
Details
CheckScoreReason
Security-Policy🟢 10security policy file detected
Dangerous-Workflow🟢 10no dangerous workflow patterns detected
Packaging⚠️ -1packaging workflow not detected
Code-Review🟢 5Found 15/27 approved changesets -- score normalized to 5
CII-Best-Practices⚠️ 0no effort to earn an OpenSSF best practices badge detected
Maintained🟢 57 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 5
Binary-Artifacts🟢 10no binaries found in the repo
Token-Permissions⚠️ 0detected GitHub workflow tokens with excessive permissions
Pinned-Dependencies⚠️ 0dependency not pinned by hash detected -- score normalized to 0
Fuzzing🟢 10project is fuzzed
License🟢 10license file detected
Branch-Protection⚠️ -1internal error: error during branchesHandler.setup: internal error: some github tokens can't read classic branch protection rules: https://github.com/ossf/scorecard-action/blob/main/docs/authentication/fine-grained-auth-token.md
Signed-Releases⚠️ -1no releases found
SAST⚠️ 0SAST tool is not run on all commits -- score normalized to 0
cargo/pest_meta 2.8.7 🟢 5.8
Details
CheckScoreReason
Security-Policy🟢 10security policy file detected
Dangerous-Workflow🟢 10no dangerous workflow patterns detected
Packaging⚠️ -1packaging workflow not detected
Code-Review🟢 5Found 15/27 approved changesets -- score normalized to 5
CII-Best-Practices⚠️ 0no effort to earn an OpenSSF best practices badge detected
Maintained🟢 57 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 5
Binary-Artifacts🟢 10no binaries found in the repo
Token-Permissions⚠️ 0detected GitHub workflow tokens with excessive permissions
Pinned-Dependencies⚠️ 0dependency not pinned by hash detected -- score normalized to 0
Fuzzing🟢 10project is fuzzed
License🟢 10license file detected
Branch-Protection⚠️ -1internal error: error during branchesHandler.setup: internal error: some github tokens can't read classic branch protection rules: https://github.com/ossf/scorecard-action/blob/main/docs/authentication/fine-grained-auth-token.md
Signed-Releases⚠️ -1no releases found
SAST⚠️ 0SAST tool is not run on all commits -- score normalized to 0
cargo/ucd-trie 0.1.7 🟢 3.2
Details
CheckScoreReason
Maintained⚠️ 00 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Code-Review⚠️ 1Found 3/26 approved changesets -- score normalized to 1
Token-Permissions⚠️ 0detected GitHub workflow tokens with excessive permissions
Packaging⚠️ -1packaging workflow not detected
Dangerous-Workflow🟢 10no dangerous workflow patterns detected
Binary-Artifacts🟢 10no binaries found in the repo
Pinned-Dependencies⚠️ 0dependency not pinned by hash detected -- score normalized to 0
CII-Best-Practices⚠️ 0no effort to earn an OpenSSF best practices badge detected
Security-Policy⚠️ 0security policy file not detected
Fuzzing⚠️ 0project is not fuzzed
Signed-Releases⚠️ -1no releases found
License🟢 10license file detected
Branch-Protection⚠️ -1internal error: error during branchesHandler.setup: internal error: some github tokens can't read classic branch protection rules: https://github.com/ossf/scorecard-action/blob/main/docs/authentication/fine-grained-auth-token.md
SAST⚠️ 0SAST tool is not run on all commits -- score normalized to 0

Scanned Files

  • rust/Cargo.lock

@Tehforsch
Tehforsch force-pushed the integration-and-api-tests branch 10 times, most recently from c9310c4 to 1a461e2 Compare July 16, 2026 12:32
@Tehforsch
Tehforsch force-pushed the integration-and-api-tests branch 13 times, most recently from 9ded6d2 to 016cf15 Compare July 22, 2026 10:53
@Tehforsch
Tehforsch marked this pull request as ready for review July 22, 2026 11:30
@Tehforsch
Tehforsch requested a review from a team as a code owner July 22, 2026 11:30
@Tehforsch
Tehforsch force-pushed the integration-and-api-tests branch from 016cf15 to 20c6683 Compare July 23, 2026 08:46
Tehforsch added 29 commits July 23, 2026 18:18
This will allow customizing the `Request` in the future to allow neat
ergonomics like `t.request(...).wait_for_status(...)`
These tests use openvas, but openvas has a global configuration pointing
it at port 3000. We could thread a custom config for each openvas
instance with different ports through the entire `openvasd` code, but I
don't want to do that because it seems brittle, so instead we introduce 
a global lock on the openvas instance which all tests which use openvas
compete for.
@Tehforsch
Tehforsch force-pushed the integration-and-api-tests branch from 20c6683 to 912e481 Compare July 23, 2026 16:18
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.

1 participant