name: Frontend Testing

on:
  pull_request:
    branches:
      - development

jobs:
  run:
    runs-on: ${{ matrix.operating-system }}
    strategy:
      matrix:
        operating-system: [ubuntu-latest]
        node: ['16', '18']
    name: Node ${{ matrix.node }} build testing
    steps:
      - uses: actions/checkout@v4
      - name: Setup node
        uses: actions/setup-node@v3
        with:
          node-version: ${{ matrix.node }}
      - name: Install frontend dependencies
        run: npm install
      - name: Try to build the assets
        run: npm run build
