-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
35 lines (31 loc) · 1.13 KB
/
.travis.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
language: c
os: linux
dist: xenial
matrix:
include:
# Build and test against a range of versions
- env: NIMVERSION=1.4.4
services:
mysql
- env: NIMVERSION=1.2.8
services:
mysql
- env: NIMVERSION=1.0.2
services:
mysql
install:
- curl https://nim-lang.org/download/nim-$NIMVERSION-linux_x64.tar.xz | xzcat | tar -C "$HOME" -xf -
- export PATH=$HOME/nim-$NIMVERSION/bin:$HOME/.nimble/bin:$PATH
- echo "export PATH=$PATH" >> ~/.profile
before_script:
- mysql -h 127.0.0.1 -u root -e "create database if not exists test;"
- mysql -h 127.0.0.1 -u root -e "create user 'nimtest'@'127.0.0.1' identified WITH mysql_native_password by '123456';"
- mysql -h 127.0.0.1 -u root -e "grant all on test.* to 'nimtest'@'127.0.0.1';"
script:
- nimble check
- nim c -d:test -d:ssl -r asyncmysql.nim
- nim c -d:test test_sql.nim
- ./test_sql --no-ssl -D test -h localhost -u nimtest --password 123456
- nim c -d:ssl -d:test test_sql.nim
- ./test_sql --no-ssl -D test -h localhost -u nimtest --password 123456
- ./test_sql --ssl --allow-mitm -D test -h localhost -u nimtest --password 123456