forked from kubeflow/model-registry
-
Notifications
You must be signed in to change notification settings - Fork 8
61 lines (61 loc) · 2.27 KB
/
run-robot-tests.yaml
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
name: run-robot-tests
run-name: Run Robot Framework tests
# Run workflow
on:
# For every push to repository
push:
# To any branch
branches:
- "*"
# For every pull request
pull_request:
# But ignore this paths
paths-ignore:
- "LICENSE*"
- "DOCKERFILE*"
- "**.gitignore"
- "**.md"
- "**.txt"
- ".github/ISSUE_TEMPLATE/**"
- ".github/dependabot.yml"
- "docs/**"
- "scripts/**"
# Define workflow jobs
jobs:
# Job runs Robot Framework tests against locally build image from current code
run-robot-tests:
# Ubuntu latest is sufficient system for run
runs-on: ubuntu-latest
# Define steps of job
steps:
# Get checkout action to get this repository
- uses: actions/checkout@v4
# Install defined Python version to run Robot Framework tests
- name: Install Python 3.9.x
# Get setup-python action to install Python
uses: actions/setup-python@v5
with:
# Set Python version to install
python-version: "3.9"
# Set architecture of Python to install
architecture: "x64"
# Install required Python packages for running Robot Framework tests
- name: Install required Python packages
# Install required Python packages using pip
run: pip install -r test/robot/requirements.txt
# Install model_registry Python package from current code
- name: Install model_registry Python package
# Install model_registry package as editable using pip
run: pip install -e clients/python
# Start docker compose with locally build image from current code
- name: Start docker compose with local image
# Start docker compose in the background
run: docker compose -f docker-compose-local.yaml up --detach
# Run Robot Framework tests in REST mode against running docker compose
- name: Run Robot Framework tests (REST mode)
# Run Robot Framework tests in REST mode from test/robot directory
run: robot test/robot
# Shutdown docker compose with locally build image from current code
- name: Shutdown docker compose with local image
# Shutdown docker compose running in the background
run: docker compose -f docker-compose-local.yaml down