-
Notifications
You must be signed in to change notification settings - Fork 15
99 lines (87 loc) · 3.04 KB
/
dev-tests.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
name: ROBOT enanomapper-dev build test
on:
workflow_dispatch:
workflow_run:
workflows: ["Build slims"]
types:
- completed
jobs:
robot-workflows:
runs-on: ubuntu-latest
steps:
- name: checkout repo
uses: actions/checkout@v4
- name: retrieve urls from config file
run: |
config_file="config.yaml"
robot_jar=""
robot=""
slimmer=""
while IFS=":" read -r key value; do
key=$(echo "$key" | tr -d '[:space:]')
case "$key" in
robot-jar)
robot_jar=$(echo "$value" | tr -d '[:space:]')
;;
robot-wrapper)
robot=$(echo "$value" | tr -d '[:space:]')
;;
esac
done < "$config_file"
echo 'robot='${robot}'' >> $GITHUB_ENV
echo 'robot_jar='${robot_jar}'' >> $GITHUB_ENV
echo ROBOT JAR: $robot_jar
echo ROBOT WRAPPER: $robot
- name: get robot
run: |
ls
wget ${{ env.robot }}
wget ${{ env.robot_jar }}
mkdir -p robot-report
- name: merge
run: |
sh robot merge -i enanomapper-dev.owl -o enanomapper-dev-full.owl
sh robot merge -i enanomapper.owl -o enanomapper-full.owl
# Upload owl artifacts
- name: 'Upload enanomapper* artifacts'
uses: actions/upload-artifact@v3
with:
name: enanomapper-files
path: enanomapper*
- name: report
run: sh robot report --fail-on none -i enanomapper-dev-full.owl -o robot-report/report.tsv
- name: diff
run: |
sh robot diff --left enanomapper-full.owl --right enanomapper-dev-full.owl --output robot-report/diff.txt
- name: reason
run: |
sh robot reason --reasoner ELK --input enanomapper-dev-full.owl -D debug-dev.owl
sh robot reason --reasoner ELK --input enanomapper-full.owl -D debug.owl
FILE=debug*
if test -f "$FILE"; then
echo $(DEBUG=True) >> $GITHUB_ENV
fi
- name: rm temp owl files
run: |
rm enanomapper-full.owl
rm enanomapper-dev-full.owl
# Upload debug artifacts
- name: 'Upload enanomapper* artifacts'
uses: actions/upload-artifact@v3
if: ${{ env.DEBUG }}
with:
name: debug-files
path: debug*
- name: 'Upload report'
uses: actions/upload-artifact@v3
with:
name: report
path: ./robot-report/*
- name: Create issue about failure
if: failure()
uses: JasonEtco/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
filename: .github/action-issue-template.md
update_existing: true