chore(deps): refresh dependencies #78
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: Test | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| workflow_dispatch: | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| # 22 is the oldest Node still in support; 24 is the LTS the consuming | |
| # apps now run on. Testing only the newest would leave consumers on 22 | |
| # unverified. Node 18 is omitted despite engines.node — it went EOL in | |
| # April 2025. | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| node-version: ['22', '24'] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v7 | |
| - name: Set up Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v7 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| - name: Install Dependencies | |
| run: npm install | |
| - name: Format Check | |
| run: npm run format:check | |
| - name: Lint | |
| run: npm run lint | |
| - name: Type Check | |
| run: npm run typecheck | |
| - name: Run Tests | |
| run: npm run test | |
| - name: Build | |
| run: npm run build | |
| - name: Validate Package Structure | |
| run: | | |
| # Check that the compiled library exists after build | |
| test -d dist || { echo "Missing dist/ — build did not emit output"; exit 1; } | |
| test -f package.json || { echo "Missing package.json"; exit 1; } | |
| test -f README.md || { echo "Missing README.md"; exit 1; } | |
| test -f LICENSE || { echo "Missing LICENSE"; exit 1; } | |
| echo "✅ Package structure validated" | |
| - name: Verify dist loads under Node ESM | |
| # The unit tests run against src/; this guards the *built* dist against | |
| # invalid ESM (e.g. extensionless relative imports), which a bundler | |
| # tolerates but Node / vitest / Next.js consumers reject. | |
| run: | | |
| node --input-type=module -e " | |
| await import('./dist/index.js'); | |
| await import('./dist/adapters/index.js'); | |
| console.log('✅ dist resolves under Node ESM'); | |
| " |