-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (53 loc) · 1.5 KB
/
test.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
name: tests
on:
pull_request:
branches:
- "add_workflow"
push:
branches:
- "add_workflow"
concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-latest
name: Check Modules on ${{ github.event_name }}
env:
REPO_NAME: Addons-Controllo-Accessi
ODOO_RC: odoo.cfg
ADDONS_PATH: /opt/odoo/addons,/mnt/$REPO_NAME
services:
postgres:
image: postgres:16.2
env:
POSTGRES_USER: odoo
POSTGRES_PASSWORD: odoo
POSTGRES_DB: odoo
ports:
- 5432:5432
steps:
- uses: docker-practice/actions-setup-docker@master
timeout-minutes: 12
- run: |
set -x
docker version
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: actions/checkout@v4
with:
repository: INRIM/Odoo-Qa
path: oqa
ref: '17.0'
token: ${{ secrets.CA_TOKEN }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade manifestoo
python -m pip install --upgrade coverage
touch $ODOO_RC
- name: Init Data
run: ${PWD}/oqa/bin/init_repo.sh
- name: Tests
run: docker run -v ${PWD}/oqa/bin/run_tests.sh:/mnt/tests/runtests.sh -v ${PWD}/:/mnt/${REPO_NAME} -v ${PWD}/${ODOO_RC}:/etc/odoo/odoo.conf --network=host odoo:17.0 /mnt/tests/runtests.sh odoo ${ADDONS} inrim