Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .claude/run-e2e-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ acquire_token() {
fi

# Generate token using the Python script
if ! uv run "$SCRIPT_DIR/get_github_app_token.py" > "$TOKEN_FILE" 2>/dev/null; then
if ! uv run "$PROJECT_ROOT/tests/get_github_app_token.py" > "$TOKEN_FILE" 2>/dev/null; then
log_error "Failed to generate GitHub App token"
return 1
fi
Expand Down
39 changes: 39 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Tests

on:
pull_request:
branches: ['*']

jobs:
unit-tests:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Run unit tests
run: bash tests/test_update_pr_stack.sh

e2e-tests:
name: E2E Tests
runs-on: ubuntu-latest
# Only run if secrets are available (not available on forks)
if: github.event.pull_request.head.repo.full_name == github.repository
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v4
with:
version: "latest"

- name: Run e2e tests
env:
GH_APP_ID: ${{ vars.GH_APP_ID }}
GH_APP_PRIVATE_KEY_PEM_B64: ${{ secrets.GH_APP_PRIVATE_KEY_PEM_B64 }}
run: |
export GH_TOKEN=$(uv run tests/get_github_app_token.py)
gh auth setup-git
bash tests/test_e2e.sh
File renamed without changes.
Loading