-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
42 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: Setup Environment | ||
|
||
on: | ||
workflow_call: | ||
|
||
jobs: | ||
setup: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Bun | ||
uses: oven-sh/setup-bun@v2 | ||
with: | ||
bun-version: 1.1.42 | ||
|
||
- name: Install Dependencies | ||
run: bun install --frozen-lockfile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,68 +1,46 @@ | ||
name: Bun Pipeline | ||
|
||
on: | ||
push: | ||
pull_request: | ||
|
||
jobs: | ||
setup: | ||
code-checks: | ||
name: "Format, Lint, and Types Check" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
- name: Setup Environment | ||
uses: ./.github/workflows/setup-environment.yml | ||
|
||
- name: Install Bun | ||
uses: oven-sh/setup-bun@v2 | ||
with: | ||
bun-version: 1.1.42 | ||
|
||
- name: Install Dependencies | ||
run: bun install --frozen-lockfile | ||
- name: Run Format, Lint, and Types Check | ||
run: bun run check-all | ||
|
||
check-all: | ||
needs: setup | ||
unit-tests: | ||
name: "Unit Tests" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
- name: Setup Environment | ||
uses: ./.github/workflows/setup-environment.yml | ||
|
||
- name: Install Bun | ||
uses: oven-sh/setup-bun@v2 | ||
with: | ||
bun-version: 1.1.42 | ||
|
||
- name: Run Formatting, Linting, and Type Checking | ||
run: bun run check-all | ||
- name: Run Unit Tests | ||
run: bun test | ||
|
||
playwright-tests: | ||
needs: setup | ||
e2e-tests: | ||
name: "E2E Tests" | ||
timeout-minutes: 5 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Bun | ||
uses: oven-sh/setup-bun@v2 | ||
with: | ||
bun-version: 1.1.42 | ||
- name: Setup Environment | ||
uses: ./.github/workflows/setup-environment.yml | ||
|
||
- name: Install Playwright Browsers | ||
run: bunx playwright install --with-deps | ||
|
||
- name: Run Playwright Tests | ||
- name: Run E2E Tests | ||
run: bun run test:e2e | ||
|
||
unit-tests: | ||
needs: setup | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Bun | ||
uses: oven-sh/setup-bun@v2 | ||
- uses: actions/upload-artifact@v4 | ||
if: ${{ !cancelled() }} | ||
with: | ||
bun-version: 1.1.42 | ||
|
||
- name: Run Unit Tests | ||
run: bun test | ||
name: playwright-report | ||
path: playwright-report/ | ||
retention-days: 30 |