forked from BrikerMan/Kashgari
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
71 lines (60 loc) · 2.03 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
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
language: python
dist: xenial
env:
global:
- COVERALLS_PARALLEL=true
matrix:
# Scoring
- TEST_FILE=tests/scoring
# Labeling
- TEST_FILE=tests/labeling/
# classification part 1
- TEST_FILE="tests/classification/test_cnn_lstm.py tests/classification/test_cnn_gru.py tests/classification/test_cnn.py tests/classification/test_kmax_cnn.py"
# classification part 2
- TEST_FILE="tests/classification/test_r_cnn.py tests/classification/test_dropout_bigru.py tests/classification/test_avcnn.py tests/classification/test_bi_gru.py"
# classification part 3
- TEST_FILE="tests/classification/test_dpcnn.py tests/classification/test_bi_lstm.py tests/classification/test_avrnn_model.py tests/classification/test_dropout_avrnn.py"
- TEST_FILE="tests/test_callbacks.py tests/test_corpus.py tests/test_processor.py"
- TEST_FILE=tests/test_custom_multi_output_classification.py
# Embedding
- TEST_FILE=tests/embedding/
# Tokenizer
- TEST_FILE=tests/test_tokenizer.py
python:
- "3.6"
cache: pip
before_install:
- export BOTO_CONFIG=/dev/null
stages:
- Lint
- name: Test
if: (branch = master) OR (type IN (pull_request))
install:
- pip install jieba
- pip install python-coveralls
- pip install -e .
- pip install tensorflow==1.14.0
- pip install pytest-cov
- pip install pytest
- python -c "import kashgari;print(f'kashgari version {kashgari.__version__}')"
- git fetch --unshallow --quiet
- export PYTHONPATH=`pwd`
#script: nosetests --with-coverage --cover-html --cover-html-dir=htmlcov
# --cover-xml --cover-xml-file=coverage.xml --with-xunit
# --cover-package="kashgari"
# $TEST_FILE
script: pytest --doctest-modules --junitxml=test-reports/junit.xml
--cov=kashgari --cov-report=xml:coverage.xml --cov-report=html:htmlcov
$TEST_FILE
after_script:
- coveralls
notifications:
webhooks: https://coveralls.io/webhook
jobs:
include:
- stage: Lint
python: "3.6"
install:
- pip install flake8 flake8-builtins
script:
- flake8 kashgari