-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
29 lines (29 loc) · 1.18 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
sudo: required
dist: bionic
language: python
matrix:
include:
- language: python
python: 3.7
cache: pip
before_install: cd api_server
install:
- pip install -r requirements.txt
services:
- postgresql
addons:
postgresql: '10'
before_script:
- psql -U postgres -c "CREATE DATABASE chat_with_anyone;"
- psql -U postgres -c "CREATE DATABASE test_chat_with_anyone;"
- psql -c "CREATE USER chat_with_anyone WITH PASSWORD 'chat_with_anyone';" -U postgres
- psql -c "ALTER ROLE chat_with_anyone SET client_encoding TO 'utf8';" -U postgres
- psql -c "ALTER ROLE chat_with_anyone SET default_transaction_isolation TO 'read committed';" -U postgres
- psql -c "ALTER ROLE chat_with_anyone SET timezone TO 'UTC';" -U postgres
- psql -c "GRANT ALL PRIVILEGES ON DATABASE chat_with_anyone TO chat_with_anyone;" -U postgres
- psql -c "GRANT ALL PRIVILEGES ON DATABASE test_chat_with_anyone TO chat_with_anyone;" -U postgres
- psql -c "ALTER USER chat_with_anyone CREATEDB;" -U postgres
- alembic upgrade head
script:
- pytest
- pylint chat_with_anyone