Parser harness: all parsers #3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Extended cross-parser validation: builds external MRT parsers (mrtparse, | |
| # bgpdump, bgpkit-parser, FastNetMon's FlowSpec decoder) in Docker and runs | |
| # them over freshly generated corpora, including the field-level route-list | |
| # and FlowSpec checks. | |
| # Manual-only: parser images are rebuilt from upstream on every run, so this | |
| # is slower and less hermetic than the unit tests. | |
| name: Parser harness | |
| run-name: "Parser harness: ${{ inputs.parsers || 'all parsers' }}${{ inputs.strict && ' (strict)' || '' }}" | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| parsers: | |
| description: "Parsers to run, space-separated (mrtparse bgpdump bgpkit-parser fastnetmon); empty runs all" | |
| required: false | |
| default: "" | |
| strict: | |
| description: "Also fail on malformed-corpus and fatal-tail parser errors" | |
| type: boolean | |
| required: false | |
| default: false | |
| jobs: | |
| parser-harness: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 90 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2 | |
| - name: Unit tests | |
| run: cargo test | |
| - name: Run parser harness | |
| run: tests/parsers/run-docker.sh ${{ inputs.strict && '--strict' || '' }} ${{ inputs.parsers }} |