Skip to content

Commit b3ed18e

Browse files
committed
adding
1 parent 64c9041 commit b3ed18e

File tree

2 files changed

+96
-0
lines changed

2 files changed

+96
-0
lines changed

.github/workflows/test.yml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
pull_request:
7+
branches: ["main"]
8+
9+
# Allows you to run this workflow manually from the Actions tab
10+
workflow_dispatch:
11+
12+
jobs:
13+
linters:
14+
name: Linters
15+
runs-on: macos-latest
16+
steps:
17+
- name: Checkout Branch
18+
uses: actions/checkout@v3
19+
- name: Setup Node
20+
uses: actions/setup-node@v3
21+
with:
22+
node-version: 18.13.0
23+
- name: Install
24+
run: npm install
25+
- name: Run linters
26+
run: npm run format
27+
- name: Check if anything changed
28+
run: |
29+
git_status="`LC_ALL=C git status --porcelain --ignore-submodules -unormal 2>&1`"
30+
if [ -n "$git_status" ]; then
31+
printf "Some file(s) changed as the result of formatting, this means that you need to run the formatter on your patch.\n"
32+
printf "Here is what changed:\n"
33+
printf -- "$git_status\n\n"
34+
printf "And here is the diff:\n"
35+
git diff -U8
36+
exit 1
37+
fi
38+
build:
39+
name: Build
40+
runs-on: macos-latest
41+
strategy:
42+
matrix:
43+
browser: [chrome, firefox, safari]
44+
steps:
45+
- name: Install Firefox
46+
if: ${{ matrix.browser == 'firefox' }}
47+
run: brew install --cask firefox
48+
- name: Checkout Branch
49+
uses: actions/checkout@v3
50+
- name: Setup Node
51+
uses: actions/setup-node@v3
52+
with:
53+
node-version: 18.13.0
54+
- name: Install
55+
run: npm install
56+
- name: Run tests
57+
run: |
58+
echo "Running in $BROWSER"
59+
npm run test:${{ matrix.browser }}

package.json

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"name": "jetstream",
3+
"version": "3.0.0-alpha",
4+
"description": "An open source repository for the JetStream benchmark.",
5+
"engines": {
6+
"node": ">=18.13.0",
7+
"npm": ">=8.19.3"
8+
},
9+
"repository": {
10+
"type": "git",
11+
"url": "git+https://github.com/WebKit/JetStream.git"
12+
},
13+
"bugs": {
14+
"url": "https://github.com/WebKit/JetStream/issues"
15+
},
16+
"license": "SEE LICENSE IN LICENSE",
17+
"scripts": {
18+
"dev": "http-server ./ -c-1 --cors",
19+
"server": "http-server ./ --cors",
20+
"lint:check": "eslint **/*.{js,mjs,jsx,ts,tsx}",
21+
"lint:fix": "eslint \"**/*.{js,mjs,jsx,ts,tsx}\" --fix",
22+
"pretty:check": "prettier --check ./",
23+
"pretty:fix": "prettier --write ./",
24+
"format": "npm run pretty:fix && npm run lint:fix"
25+
},
26+
"devDependencies": {
27+
"@babel/core": "^7.21.3",
28+
"@babel/eslint-parser": "^7.21.3",
29+
"@babel/plugin-proposal-decorators": "^7.21.0",
30+
"command-line-args": "^5.2.1",
31+
"command-line-usage": "^6.1.3",
32+
"eslint": "^8.38.0",
33+
"http-server": "^14.1.1",
34+
"prettier": "^2.8.3",
35+
"selenium-webdriver": "^4.8.0"
36+
}
37+
}

0 commit comments

Comments
 (0)