-
Notifications
You must be signed in to change notification settings - Fork 76
50 lines (44 loc) · 1.23 KB
/
e2e.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
name: Testing era_test_node using e2e
on:
workflow_call:
jobs:
e2e:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
name: e2e
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-node@v3
with:
node-version: 18.x
cache: "yarn"
cache-dependency-path: 'e2e-tests/yarn.lock'
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: era_test_node-${{ matrix.os }}.tar.gz
- name: Start the era_test_node
id: start_node
run: |
echo "Extracting era_test_node binary"
tar -xzf era_test_node-${{ matrix.os }}.tar.gz
chmod +x era_test_node
echo "Starting node in background"
./era_test_node 2>&1 | tee era_test_node_output.log &
echo "PID=$!" >> $GITHUB_ENV
- name: Launch tests
id: launch
run: |
echo "Run tests"
make test-e2e
- name: Stop the era_test_node and print output logs
id: stop_node
if: always()
run: |
cat era_test_node_output.log
kill $PID