Skip to content

Commit 4988734

Browse files
ylobankovLeonidVas
authored andcommitted
github-ci: add simple CI based on GitHub actions
- Add new .github/workflows/fast_testing.yml file - Delete old .travis.yml file - Delete old .travis/test.sh script - Delete old Jenkinsfile script In the provided workflow we install tarantool (1.10, 2.8, 2.9) and just run tests from the module against it. Closes #63
1 parent e9e6fb6 commit 4988734

File tree

4 files changed

+61
-220
lines changed

4 files changed

+61
-220
lines changed

.github/workflows/fast_testing.yml

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
name: fast_testing
2+
3+
on:
4+
workflow_dispatch:
5+
pull_request:
6+
push:
7+
branches:
8+
- 'master'
9+
tags:
10+
- '*'
11+
12+
jobs:
13+
run_tests:
14+
runs-on: ubuntu-latest
15+
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
tarantool:
20+
- '1.10'
21+
- '2.8'
22+
- '2.9'
23+
24+
env:
25+
MYSQL_HOST: 127.0.0.1
26+
MYSQL_PORT: 3306
27+
MYSQL_USER: tarantool
28+
MYSQL_DATABASE: tarantool_mysql_test
29+
30+
steps:
31+
- name: Clone the module
32+
uses: actions/checkout@v2
33+
with:
34+
submodules: recursive
35+
36+
- name: Setup tarantool ${{ matrix.tarantool }}
37+
uses: tarantool/setup-tarantool@v1
38+
with:
39+
tarantool-version: ${{ matrix.tarantool }}
40+
41+
# Workaround to avoid issue https://github.com/tarantool/mysql/issues/47.
42+
- name: Update mysql server config
43+
run: |
44+
sudo sed -i 's/\[mysqld\]/\[mysqld\]\ncharacter-set-server = utf8/' \
45+
/etc/mysql/mysql.conf.d/mysqld.cnf
46+
sudo systemctl restart mysql
47+
48+
- name: Prepare test environment
49+
run: |
50+
sudo mysql -proot -e "CREATE USER ${MYSQL_USER}@${MYSQL_HOST};"
51+
sudo mysql -proot -e "GRANT ALL PRIVILEGES ON *.* \
52+
TO ${MYSQL_USER}@${MYSQL_HOST};"
53+
sudo mysql -proot -e "ALTER USER ${MYSQL_USER}@${MYSQL_HOST} \
54+
IDENTIFIED WITH mysql_native_password BY '';"
55+
sudo mysql -proot -e "CREATE DATABASE ${MYSQL_DATABASE};"
56+
57+
- run: cmake . && make
58+
- run: make check
59+
env:
60+
MYSQL: '${{ env.MYSQL_HOST }}:${{ env.MYSQL_PORT }}:${{
61+
env.MYSQL_USER }}::${{ env.MYSQL_DATABASE }}'

.travis.yml

Lines changed: 0 additions & 179 deletions
This file was deleted.

.travis/test.sh

Lines changed: 0 additions & 33 deletions
This file was deleted.

Jenkinsfile

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)