-
Notifications
You must be signed in to change notification settings - Fork 19
112 lines (96 loc) · 3.57 KB
/
github-actions-ubuntu.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
100
101
102
103
104
105
106
107
108
109
110
111
112
#name: he
#
#on:
# push:
# branches: [main]
# pull_request:
# branches: [main]
#
#jobs:
# build:
#
# runs-on: ${{ matrix.os }}
#
# strategy:
# matrix:
# os: [ubuntu-latest, macos-latest, windows-latest]
# python-version: [3.6, 3.7, 3.8, 3.9]
#
# steps:
# - uses: actions/checkout@v2
#
# - name: Set up Python ${{ matrix.python-version }}
# uses: actions/setup-python@v2
# with:
# python-version: ${{ matrix.python-version }}
#
# - name: Install dependencies
# run: |
# python -m pip install --upgrade pip
# pip install Cython pytest
#
# - name: Build and test
# run: |
# python setup.py build_ext --inplace
# pytest
name: graphkit-learn
run-name: ${{ github.actor }} is testing graphkit-learn out GitHub Actions 🚀
on: [ push, pull_request ]
jobs:
CI-Ubuntu:
runs-on: ${{ matrix.os }}
strategy:
matrix:
# os: [ubuntu-latest, macos-latest, windows-latest]
os: [ubuntu-latest]
python-version: ["3.8", "3.9", "3.10"]
steps:
- run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event."
- run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by GitHub!"
- run: echo "🔎 The name of your branch is ${{ github.ref }} and your repository is ${{ github.repository }}."
- name: Check out repository code
uses: actions/checkout@v3
- run: echo "💡 The ${{ github.repository }} repository has been cloned to the runner."
- run: echo "🖥️ The workflow is now ready to test your code on the runner."
- run: echo "🪵 The root directory of the file system is ${{ github.workspace }}."
- name: List files in the repository
run: |
pwd
ls /
echo "The files contained in the repository (github.workspace):"
ls ${{ github.workspace }}
- run: echo "🍏 This job's status is ${{ job.status }}."
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'pip' # caching pip dependencies
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install Cython pytest
pip install codecov coverage pytest-cov
sudo apt-get -y install gfortran liblapack-dev
pip install -r requirements.txt
pip install wheel
- name: Build and test
run: |
# python setup.py bdist_wheel
python setup.py install
# pytest -v --cov-config=.coveragerc --cov-report term --cov=gklearn gklearn/tests/ged/
pytest -v --cov-config=.coveragerc --cov-report term --cov=gklearn gklearn/tests/ --ignore=gklearn/tests/test_median_preimage_generator.py --ignore=gklearn/tests/test_graphkernels.py --ignore=gklearn/tests/ged/test_gedlib.py
- name: Run code coverage
run: |
codecov
# - name: Publish distribution 📦 to Test PyPI
# if: matrix.python-version == '3.8' && matrix.os == 'ubuntu-latest'
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# password: ${{ secrets.TEST_PYPI_API_TOKEN }}
# repository-url: https://test.pypi.org/legacy/
# - name: Publish distribution 📦 to PyPI
# if: matrix.python-version == '3.8' && matrix.os == 'ubuntu-latest'
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# user: __token__
# password: ${{ secrets.PYPI_API_TOKEN }}