Skip to content

Add compatibility badge and skip Swagger 2.0 schemas in test_openapi_directory#26

Merged
phalt merged 5 commits intomainfrom
copilot/add-badge-to-readme
Dec 24, 2025
Merged

Add compatibility badge and skip Swagger 2.0 schemas in test_openapi_directory#26
phalt merged 5 commits intomainfrom
copilot/add-badge-to-readme

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Dec 23, 2025

Plan

  • Update test_openapi_directory.py to skip Swagger 2.0 schemas
    • Add skipped count tracking
    • Modify test_schema_file to return status (success/skipped/failed)
    • Update test_all_schemas to handle skipped status
    • Update summary to calculate success rate excluding skipped schemas
    • Fix version handling to work with both string and numeric swagger versions
    • Add empty string check to prevent IndexError
    • Output 0.00% instead of N/A for consistency with badge extraction
    • Fix linting errors (trailing whitespace and formatting)
  • Update .github/workflows/test-openapi-directory.yml workflow
    • Change permissions from read to write
    • Capture test output to file
    • Extract percentage from output
    • Fix regex pattern to handle both decimal and whole number percentages
    • Create compatibility.json file
    • Commit and push the badge data
  • Create .github/compatibility.json bootstrap file
  • Update README.md to add the compatibility badge
Original prompt

See the changes to this pull request to enable us to add a badge to the project's readme: phalt/clientele#90. I want to do the same for the cicerone project. Also you will notice that the clientele version of test_openapi_directory will skip over swagger / 2.0 schemas - we should copy that functionality exactly as we only care about openapi 3.0 and up versions.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI and others added 3 commits December 23, 2025 16:11
Co-authored-by: phalt <490685+phalt@users.noreply.github.com>
…ling

Co-authored-by: phalt <490685+phalt@users.noreply.github.com>
…tage output

Co-authored-by: phalt <490685+phalt@users.noreply.github.com>
Copilot AI changed the title [WIP] Add badge to README and update test_openapi_directory Add compatibility badge and skip Swagger 2.0 schemas in test_openapi_directory Dec 23, 2025
Copilot AI requested a review from phalt December 23, 2025 16:18
@phalt
Copy link
Copy Markdown
Owner

phalt commented Dec 23, 2025

@copilot linting errors! Check the CI file to see how we set up the project and run linting and ensure all steps pass locally before committing changes.

Co-authored-by: phalt <490685+phalt@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Dec 23, 2025

@copilot linting errors! Check the CI file to see how we set up the project and run linting and ensure all steps pass locally before committing changes.

Fixed the linting errors. Removed trailing whitespace from blank lines and ran ruff formatter on the file. All linting checks now pass. (commit 2ca775f)

@phalt phalt marked this pull request as ready for review December 24, 2025 05:40
@codecov-commenter
Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.62%. Comparing base (aecf34d) to head (2ca775f).
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #26   +/-   ##
=======================================
  Coverage   99.62%   99.62%           
=======================================
  Files          30       30           
  Lines         804      804           
  Branches       72       72           
=======================================
  Hits          801      801           
  Partials        3        3           

☔ 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.

@phalt phalt merged commit 26ea4e6 into main Dec 24, 2025
5 checks passed
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.

3 participants