-
-
Notifications
You must be signed in to change notification settings - Fork 21
91 lines (78 loc) · 2.59 KB
/
test.workflows.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
name: Test
# when it active ?
on:
workflow_dispatch:
inputs:
name:
description: "run name"
default: "default"
push:
branches:
- devel
- github-ci
pull_request:
branches:
- devel
jobs:
# LINUX JOB
linux:
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
python_version: ['3.10.4']
steps:
- uses: actions/checkout@v2
- name: Install OS dependencies
run: |
sudo apt update
sudo apt install libxcb-icccm4 libxcb-image0 libxcb-keysyms1 \
libxkbcommon-x11-0 xvfb libxcb-randr0 \
libxcb-render-util0 libxcb-xinerama0 libegl1
- name: Install OpenGL
run: sudo apt-get install libgl1
- uses: actions/setup-python@v2
with:
python-version: ${{matrix.python_version}}
- name: install_deps
run: "make install_deps"
- name: install PySide6 # Parce que @ysard veut absolument les version deprecated
run : pip install PySide6
- name: test
run: xvfb-run -a python -m pytest tests cutevariant
- name: coverage
run: xvfb-run -a python -m pytest --cov=cutevariant --cov-report=xml
- uses: codecov/codecov-action@v2
with:
verbose: true # optional (default = false)
# WINDOWS JOB
# windows:
# runs-on: windows-latest
# strategy:
# matrix:
# architecture: ['x64', 'x86']
# steps:
# - uses: actions/checkout@v2
# - uses: actions/setup-python@v2
# with:
# python-version: '3.9'
# architecture: ${{matrix.architecture}}
# - name: install_deps
# run: "make install_deps"
# - name: install PySide6 # Parce que @ysard veut absolument les version deprecated
# run : pip install PySide6
# - name: install windows deps
# run: |
# pip install pywin32
# pip install PyInstaller==4.0
# - name: test
# run: python -m pytest tests/core
# - name: create binary
# if: contains(github.event.head_commit.message, '[deploy]')
# run: pyinstaller -i icon.ico --name="cutevariant_${{matrix.architecture}}" --hidden-import json --add-data "cutevariant;cutevariant" cutevariant\__main__.py
# - name: Upload artifact
# if: github.ref == 'refs/heads/master' || contains(github.event.head_commit.message, '[deploy]')
# uses: actions/upload-artifact@v2
# with:
# name: cutevariant-standalone-${{matrix.architecture}}
# path: dist