Skip to content

test: Add parser and contract coverage for subdomain_takeover plugin#765

Open
mythri2405 wants to merge 1 commit into
utksh1:mainfrom
mythri2405:test/subdomain-takeover-contract
Open

test: Add parser and contract coverage for subdomain_takeover plugin#765
mythri2405 wants to merge 1 commit into
utksh1:mainfrom
mythri2405:test/subdomain-takeover-contract

Conversation

@mythri2405

@mythri2405 mythri2405 commented Jun 10, 2026

Copy link
Copy Markdown

Description

This PR adds contract-level test coverage for the subdomain_takeover plugin. It ensures that plugin metadata, command rendering, and parser normalization behave consistently and do not drift silently in future changes.

The tests validate:

  • Plugin metadata loading through the existing validation pipeline
  • Correct command rendering via PluginManager
  • Parser output structure and severity classification using deterministic fixtures
  • Preservation of raw scan output in parser metadata
    This improves reliability of the plugin system by enforcing strict contracts for plugin behavior.

Related Issues

Closes #512

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

Run the full backend test suite:

pytest testing/backend -q

All tests pass successfully, including:

  • Metadata validation tests
  • PluginManager command rendering tests
  • Parser contract tests with fixed input fixtures

Checklist

  • My code follows the code style of this project.
  • I have performed a self-review of my own code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have made corresponding changes to the documentation(no docs changes required).
  • My changes generate no new warnings(excluding known upstream pytest/pydantic warnings).

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.

[TEST] Add parser and contract coverage for plugin subdomain_takeover

1 participant