docs: update game documentation for class mechanics #1145
Workflow file for this run
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: Run Tests | |
on: | |
push: | |
pull_request: | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [18.x] # Match the version specified in package.json | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' # Cache npm dependencies | |
- name: Install dependencies | |
run: npm ci # Use ci for cleaner installs in CI environments | |
# Set up Next.js build cache | |
- name: Setup Next.js Build Cache | |
uses: actions/cache@v3 | |
with: | |
path: | | |
${{ github.workspace }}/.next/cache | |
# Generate a new cache whenever packages or source files change. | |
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}-${{ hashFiles('**.[jt]s', '**.[jt]sx') }} | |
# If source files changed but packages didn't, rebuild from a prior cache. | |
restore-keys: | | |
${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}- | |
- name: Build project | |
run: npm run build | |
env: | |
# Disable Next.js telemetry in CI environment | |
NEXT_TELEMETRY_DISABLED: 1 | |
- name: Run tests | |
run: npm test | |
env: | |
NEXT_TELEMETRY_DISABLED: 1 |