Merge pull request #7 from hametuha/feature/ai-search #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
| name: WordPress Plugin Test | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| branches: | |
| - master | |
| jobs: | |
| test: | |
| strategy: | |
| matrix: | |
| php: [ '7.4', '8.3' ] | |
| wp: [ 'latest', '6.6' ] | |
| uses: tarosky/workflows/.github/workflows/wp-unit-test.yml@main | |
| with: | |
| php_version: ${{ matrix.php }} | |
| wp_version: ${{ matrix.wp }} | |
| phpcs: | |
| name: PHP Syntax Check | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup PHP with composer v2 | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: 7.4 | |
| tools: composer | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Install dependencies | |
| run: composer install --no-progress | |
| - name: PHP CodeSniffer | |
| run: composer lint | |
| phplint: | |
| uses: tarosky/workflows/.github/workflows/phplint.yml@main | |
| with: | |
| php_versions: '["7.4", "8.3"]' | |
| assets: | |
| name: Test Assets | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22' | |
| - name: Install NPM Dependencies | |
| run: npm install | |
| - name: Lint JS | |
| run: npm run lint:js | |
| - name: Lint CSS | |
| run: npm run lint:css | |
| status: | |
| name: Status Check | |
| runs-on: ubuntu-latest | |
| needs: [ test, phpcs, phplint, assets ] | |
| if: always() | |
| steps: | |
| - uses: re-actors/alls-green@release/v1 | |
| with: | |
| jobs: ${{ toJSON(needs) }} |