diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 0000000..65bda31 --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,28 @@ +name: tests +on: [pull_request] +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + node-version: [8.x] + steps: + - uses: actions/checkout@v2 + - name: Setup with Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v1 + with: + node-version: ${{ matrix.node-version }} + - name: Cache Node.js modules + uses: actions/cache@v2 + with: + path: ~/.npm + key: ${{ runner.OS }}-node-${{ hashFiles('**/package-lock.json') }} + restore-keys: | + ${{ runner.OS }}-node- + ${{ runner.OS }}- + - name: Install dependencies + run: npm install grunt-cli + - name: "Build dist files" + run: grunt build + - name: "Run tests" + run: npm test