-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
61 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,70 +1,69 @@ | ||
name: test-run | ||
|
||
on: [push, pull_request] | ||
on: [ push, pull_request ] | ||
|
||
jobs: | ||
build: | ||
if: ( github.event_name == 'push' || | ||
github.event.pull_request.head.repo.full_name != github.repository ) && | ||
( github.repository == 'tarantool/test-run' ) | ||
github.event.pull_request.head.repo.full_name != github.repository ) && | ||
( github.repository == 'tarantool/test-run' ) | ||
|
||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.8-dev] | ||
tarantool-version: [2.6, 2.7] | ||
python-version: [ 2.7, 3.5, 3.6, 3.7, 3.8, 3.9 ] | ||
tarantool-version: [ 2.7, 2.8 ] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: update git submodules | ||
run: git submodule update --init --recursive | ||
- name: set up Tarantool ${{ matrix.tarantool-version }} | ||
uses: tarantool/setup-tarantool@v1 | ||
with: | ||
tarantool-version: ${{ matrix.tarantool-version }} | ||
- name: set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: display python version | ||
run: python -c "import sys; print(sys.version)" | ||
- name: setup dependencies | ||
run: | | ||
sudo apt update -y | ||
sudo apt-get -y install lua5.1 luarocks | ||
sudo luarocks install luacheck | ||
- name: set default pip to pip3 | ||
run: | | ||
sudo rm -f /usr/local/bin/pip | ||
sudo ln -s /usr/bin/pip3 /usr/local/bin/pip | ||
- name: set default python and pip to v2.7 | ||
if: ${{ matrix.python-version }} == 2.7 | ||
run: | | ||
curl https://bootstrap.pypa.io/pip/2.7/get-pip.py --output get-pip.py | ||
sudo python2 get-pip.py | ||
sudo rm -f /usr/bin/python | ||
sudo ln -s /usr/bin/python2 /usr/bin/python | ||
sudo rm -f /usr/local/bin/pip | ||
sudo ln -s /usr/local/bin/pip2 /usr/local/bin/pip | ||
- name: setup python dependencies | ||
run: | | ||
pip install -r requirements.txt | ||
pip install -r requirements-test.txt | ||
- name: run static analysis | ||
run: | | ||
make lint | ||
- name: run regression tests | ||
run: | | ||
make test | ||
- name: code coverage | ||
if: ${{ matrix.python-version == '3.8' && matrix.tarantool-version == '2.7' }} | ||
run: | | ||
pip install coveralls==3.* | ||
make coverage | ||
- name: upload coverage data to coveralls.io | ||
if: ${{ matrix.python-version == '3.8' && matrix.tarantool-version == '2.7' }} | ||
run: coveralls --service=github | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
submodules: recursive | ||
|
||
- name: set up Tarantool ${{ matrix.tarantool-version }} | ||
uses: tarantool/setup-tarantool@v1 | ||
with: | ||
tarantool-version: ${{ matrix.tarantool-version }} | ||
|
||
- name: set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: display Python version | ||
run: python -c "import sys; print(sys.version)" | ||
|
||
- name: setup dependencies | ||
run: | | ||
sudo apt update -y | ||
sudo apt-get -y install lua5.1 luarocks | ||
sudo luarocks install luacheck | ||
- name: setup Python dependencies | ||
run: | | ||
python -m pip install -r requirements.txt | ||
python -m pip install -r requirements-test.txt | ||
- name: run static analysis | ||
run: make lint | ||
|
||
- name: run regression tests | ||
run: | | ||
sudo rm /usr/bin/python | ||
make test | ||
- name: code coverage | ||
if: ${{ matrix.python-version == '3.8' && | ||
matrix.tarantool-version == '2.7' }} | ||
run: | | ||
python -m pip install coveralls==3.* | ||
make coverage | ||
- name: upload coverage data to coveralls.io | ||
if: ${{ matrix.python-version == '3.8' && | ||
matrix.tarantool-version == '2.7' }} | ||
run: coveralls --service=github | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters