Tests: ignore security advisories for PHP_CodeSniffer #721
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
| --- | |
| name: Linting jobs | |
| on: | |
| - push | |
| - pull_request | |
| - workflow_dispatch | |
| # Cancels all previous workflow runs for the same branch that have not yet completed. | |
| concurrency: | |
| # The concurrency group contains the workflow name and the branch name. | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| validate-composer: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - name: Validate composer.json | |
| uses: "docker://composer" | |
| with: | |
| args: "composer validate --no-check-lock" | |
| lint-json: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - name: Lint json | |
| uses: "docker://pipelinecomponents/jsonlint:latest" | |
| with: | |
| args: "find . -not -path './.git/*' -name '*.json' -type f -exec jsonlint --quiet {} ;" | |
| yamllint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - name: Check yaml for issues | |
| uses: pipeline-components/yamllint@master | |
| php-codesniffer: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - name: Check php for code style and php cross-version compatibility issues | |
| uses: pipeline-components/php-codesniffer@master | |
| lint-remark: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - name: Check markdown | |
| uses: pipeline-components/remark-lint@master | |
| lint-xml: | |
| name: Check XML files | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| # Validate dev tool related XML files. | |
| - name: Validate Project PHPCS ruleset against schema | |
| uses: phpcsstandards/xmllint-validate@5189514594c8d5f4cf21b7e5af50f54d697973d7 # v2.0.0 | |
| with: | |
| pattern: phpcs.xml.dist | |
| xsd-url: https://raw.githubusercontent.com/PHPCSStandards/PHP_CodeSniffer/refs/heads/4.x/phpcs.xsd | |
| - name: Validate PHPUnit config against schema | |
| uses: phpcsstandards/xmllint-validate@5189514594c8d5f4cf21b7e5af50f54d697973d7 # v2.0.0 | |
| with: | |
| pattern: phpunit.xml.dist | |
| xsd-url: https://raw.githubusercontent.com/sebastianbergmann/phpunit/refs/heads/main/schema/9.2.xsd | |
| # Validate the XML ruleset files used in the tests. | |
| - name: Validate rulesets against schema | |
| uses: phpcsstandards/xmllint-validate@5189514594c8d5f4cf21b7e5af50f54d697973d7 # v2.0.0 | |
| with: | |
| pattern: tests/fixtures/*/*/ruleset.xml | |
| xsd-url: https://raw.githubusercontent.com/PHPCSStandards/PHP_CodeSniffer/refs/heads/4.x/phpcs.xsd |