Skip to content

Commit 8253c0a

Browse files
committed
refactor: restructure GitHub Actions workflows for reusable tests and remove redundant runner
1 parent b9fee3d commit 8253c0a

File tree

3 files changed

+44
-44
lines changed

3 files changed

+44
-44
lines changed

.github/workflows/github-apps-tests-runner.yml

Lines changed: 0 additions & 19 deletions
This file was deleted.
Lines changed: 14 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,19 @@
11
name: GitHub Apps Tests
22

33
on:
4-
workflow_call: {}
4+
push:
5+
branches: [main, develop]
6+
paths:
7+
- "openci-runner/github-apps/**"
8+
- ".github/workflows/github-apps-tests.yml"
9+
- ".github/workflows/github-apps-tests-runner.yml"
10+
pull_request:
11+
branches: [main, develop]
12+
paths:
13+
- "openci-runner/github-apps/**"
14+
- ".github/workflows/github-apps-tests.yml"
15+
- ".github/workflows/github-apps-tests-runner.yml"
516

617
jobs:
7-
test:
8-
runs-on: ubuntu-latest
9-
permissions:
10-
contents: read
11-
strategy:
12-
matrix:
13-
node-version: [20, 22]
14-
defaults:
15-
run:
16-
working-directory: openci-runner/github-apps
17-
steps:
18-
- name: Checkout repository
19-
uses: actions/checkout@v4
20-
21-
- name: Set up Node.js
22-
uses: actions/setup-node@v4
23-
with:
24-
node-version: ${{ matrix.node-version }}
25-
26-
- name: Install dependencies
27-
run: npm ci
28-
29-
- name: Run tests
30-
run: npm test
18+
call-tests:
19+
uses: ./.github/workflows/github-apps-tests.yml
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Reusable GitHub Apps Tests
2+
3+
on:
4+
workflow_call: {}
5+
6+
jobs:
7+
test:
8+
runs-on: ubuntu-latest
9+
permissions:
10+
contents: read
11+
strategy:
12+
matrix:
13+
node-version: [20, 22]
14+
defaults:
15+
run:
16+
working-directory: openci-runner/github-apps
17+
steps:
18+
- name: Checkout repository
19+
uses: actions/checkout@v4
20+
21+
- name: Set up Node.js
22+
uses: actions/setup-node@v4
23+
with:
24+
node-version: ${{ matrix.node-version }}
25+
26+
- name: Install dependencies
27+
run: npm ci
28+
29+
- name: Run tests
30+
run: npm test

0 commit comments

Comments
 (0)