Skip to content

Commit e8dcdb1

Browse files
committed
Add build & test workflow
1 parent 2b255b2 commit e8dcdb1

File tree

8 files changed

+915
-103
lines changed

8 files changed

+915
-103
lines changed

.github/workflows/build_test.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Build & Test
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
types: [opened, synchronize]
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
env:
13+
BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
14+
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
15+
WPT_MANIFEST: ${{ github.workspace }}/wpt/MANIFEST.json
16+
steps:
17+
- uses: actions/checkout@v3
18+
- uses: actions/setup-node@v3
19+
with:
20+
node-version: '16'
21+
- uses: actions/setup-python@v3
22+
with:
23+
python-version: '3.x'
24+
- uses: actions/checkout@v3
25+
with:
26+
repository: flackr/wpt
27+
path: wpt
28+
ref: 9b1100ffc2421e38a36620e6b205e17e558a113d
29+
30+
- name: Build
31+
run: |
32+
npm install
33+
npm run build
34+
35+
- name: Setup WPT
36+
run: |
37+
cd wpt
38+
pip install virtualenv
39+
./wpt make-hosts-file | sudo tee -a /etc/hosts
40+
- name: Run Tests
41+
run: |
42+
npm run serve &
43+
./wpt/wpt manifest
44+
./wpt/wpt serve --polyfill=http://bs-local.com:9606/dist/src/cqfill.iife.min.js &
45+
npm test

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
build
1+
dist
22
node_modules

0 commit comments

Comments
 (0)