-
Notifications
You must be signed in to change notification settings - Fork 245
35 lines (34 loc) · 1.08 KB
/
validate-code.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
name: Validate Topology code
on: [push, pull_request]
jobs:
validate-code:
name: Validate Topology code
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.9.15
- name: Install packages
run: |
sudo apt-get update
sudo apt-get install apache2-dev libldap2-dev libsasl2-dev libyaml-dev
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements-apache.txt
python -m pip install pytest pytest-mock
- name: Test API
run: |
export TOPOLOGY_CONFIG=$PWD/src/config-ci.py
export FLASK_DEBUG=1
py.test ./src/tests/test_api.py
- name: Test StashCache
run: |
export TOPOLOGY_CONFIG=$PWD/src/config-ci.py
export FLASK_DEBUG=1
py.test ./src/tests/test_stashcache.py
- name: Test cacher
run: |
./src/topology_cacher.py --outdir=/tmp/topology-cacher