Skip to content

Commit f904040

Browse files
authored
Chore: Github common CI action (#264)
* Introducing common CI * Adding amqp to test * Minor adjustment * name fixes * removing unused prop * typo fix * Filtering test * Removing test from PR + fixing minor issue * Issue fix
1 parent d8f09d4 commit f904040

1 file changed

Lines changed: 43 additions & 0 deletions

File tree

.github/workflows/ci.common.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Common CI
2+
on:
3+
workflow_call:
4+
inputs:
5+
working_directory:
6+
required: true
7+
type: string
8+
package_name:
9+
required: true
10+
type: string
11+
node_version:
12+
required: true
13+
type: string
14+
15+
jobs:
16+
build:
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v4
20+
21+
- name: Setup Node ${{ inputs.node_version }}
22+
uses: actions/setup-node@v4
23+
with:
24+
node-version: ${{ inputs.node_version }}
25+
26+
- name: Install
27+
run: npm install --ignore-scripts
28+
working-directory: ${{ inputs.working_directory }}
29+
30+
- name: Build TS
31+
run: npm run build
32+
working-directory: ${{ inputs.working_directory }}
33+
34+
- name: Docker start
35+
run: npm run docker:start:dev
36+
working-directory: ${{ inputs.working_directory }}
37+
38+
- name: Run Tests
39+
run: npm run test:ci -- --filter=${{ inputs.package_name }}
40+
41+
- name: Docker stop
42+
run: npm run docker:stop:dev
43+
working-directory: ${{ inputs.working_directory }}

0 commit comments

Comments
 (0)