Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add CI job to check GraphQL schema #10914

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 70 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,76 @@ jobs:

- run: npm run langs:check

check-graphql:
runs-on: ubuntu-latest
timeout-minutes: 15

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup project
uses: ./.github/actions/setup-project
with:
CACHE_VERSION: ${{ secrets.CACHE_VERSION }}

- run: npm run graphql:check

check-graphql-alt:
runs-on: ubuntu-latest
timeout-minutes: 15

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup project
uses: ./.github/actions/setup-project
with:
CACHE_VERSION: ${{ secrets.CACHE_VERSION }}

- name: Run GraphQL update
run: |
npm run graphql:update | tee /dev/stdout

- name: Check for schema changes
run: |
if [ -n "$(git status --porcelain)" ]; then
echo "Error: GraphQL schema is not up to date. Please update the schema and commit changes." && exit 1
else
echo "GraphQL schema is up to date."
fi

check-codegen:
runs-on: ubuntu-latest
timeout-minutes: 15

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup project
uses: ./.github/actions/setup-project
with:
CACHE_VERSION: ${{ secrets.CACHE_VERSION }}

- run: npm run graphql:codegen-check -- --verbose --concurrency=1

check-codegen-script:
runs-on: ubuntu-latest
timeout-minutes: 15

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup project
uses: ./.github/actions/setup-project
with:
CACHE_VERSION: ${{ secrets.CACHE_VERSION }}

- run: npm run graphql:codegen-check-script

build:
runs-on: ubuntu-latest

Expand Down
298 changes: 298 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading