add testing on push
This commit is contained in:
parent
f8a0ab6d3c
commit
e1644a58bd
1 changed files with 40 additions and 0 deletions
40
.github/workflows/Test.yml
vendored
Normal file
40
.github/workflows/Test.yml
vendored
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
name: "Test"
|
||||
|
||||
on:
|
||||
push:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
release:
|
||||
name: "Test ${{ github.ref }}"
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
-
|
||||
name: "Checkout source code"
|
||||
uses: "actions/checkout@v3.1.0"
|
||||
with:
|
||||
ref: ${{ github.ref }}
|
||||
-
|
||||
name: Set up node
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: '16'
|
||||
-
|
||||
name: Update packages
|
||||
run: sudo apt update -qq
|
||||
-
|
||||
name: Install apt packages
|
||||
run: sudo apt-get install -y libcairo2-dev libjpeg8-dev libpango1.0-dev libgif-dev build-essential g++ xvfb libgles2-mesa-dev libgbm-dev libxxf86vm-dev
|
||||
-
|
||||
name: Install node dependencies
|
||||
run: npm install
|
||||
-
|
||||
name: Download test data
|
||||
run: wget -O test_data.zip https://github.com/acalcutt/tileserver-gl/releases/download/test_data/test_data.zip
|
||||
-
|
||||
name: Unzip test data
|
||||
run: unzip -q test_data.zip -d test_data
|
||||
-
|
||||
name: Run tests
|
||||
run: xvfb-run --server-args="-screen 0 1024x768x24" npm test
|
||||
Loading…
Reference in a new issue