Skip to content

Commit 016ef82

Browse files
committed
ci: Add GitHub Actions workflows for React testing
1 parent d0badc7 commit 016ef82

File tree

5 files changed

+43
-13
lines changed

5 files changed

+43
-13
lines changed

.github/workflows/integration-tests.yml renamed to .github/workflows/core-integration-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Integration Tests
1+
name: Core Integration Tests
22

33
on:
44
push:

.github/workflows/core-unit-tests.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Core Unit Tests
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
unit-test:
11+
runs-on: ubuntu-latest
12+
13+
strategy:
14+
matrix:
15+
node-version: [22.x]
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
- name: Use Node.js ${{ matrix.node-version }}
21+
uses: actions/setup-node@v4
22+
with:
23+
node-version: ${{ matrix.node-version }}
24+
25+
- name: Install pnpm
26+
uses: pnpm/action-setup@v2
27+
with:
28+
version: 8
29+
30+
- name: Install dependencies
31+
run: pnpm install
32+
33+
- name: Run unit tests
34+
run: pnpm --filter @firebase-ui/core test:unit

.github/workflows/unit-tests.yml renamed to .github/workflows/react-unit-tests.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Unit Tests
1+
name: React Unit Tests
22

33
on:
44
push:
@@ -31,4 +31,4 @@ jobs:
3131
run: pnpm install
3232

3333
- name: Run unit tests
34-
run: pnpm --filter @firebase-ui/core test
34+
run: pnpm --filter @firebase-ui/react test

packages/firebaseui-core/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@
2323
"lint": "tsc --noEmit",
2424
"format": "prettier --write \"src/**/*.ts\" \"tests/**/*.ts\"",
2525
"clean": "rimraf dist",
26-
"test": "vitest run tests/unit",
27-
"test:watch": "vitest tests/unit",
26+
"test:unit": "vitest run tests/unit",
27+
"test:unit:watch": "vitest tests/unit",
2828
"test:integration": "vitest run tests/integration",
2929
"test:integration:watch": "vitest tests/integration",
30-
"test:all": "vitest run"
30+
"test": "vitest run"
3131
},
3232
"keywords": [
3333
"firebase",

packages/firebaseui-react/package.json

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,9 @@
2323
"lint": "tsc --noEmit",
2424
"format": "prettier --write \"src/**/*.ts\"",
2525
"clean": "rimraf dist",
26-
"test": "vitest run tests/unit",
27-
"test:watch": "vitest tests/unit",
28-
"test:integration": "vitest run tests/integration",
29-
"test:integration:watch": "vitest tests/integration",
30-
"test:e2e": "vitest run tests/e2e",
31-
"test:e2e:watch": "vitest tests/e2e",
32-
"test:all": "vitest run"
26+
"test:unit": "vitest run tests/unit",
27+
"test:unit:watch": "vitest tests/unit",
28+
"test": "vitest run"
3329
},
3430
"peerDependencies": {
3531
"@firebase-ui/core": "workspace:*",

0 commit comments

Comments
 (0)