-
Notifications
You must be signed in to change notification settings - Fork 57
/
.travis.yml
90 lines (88 loc) · 2.43 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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
dist: xenial
language: python
python:
- "3.9"
- "3.8"
- "3.7"
- "2.7"
install:
- if [ -e requirements.txt ]; then pip install -r requirements.txt ; fi
- if [ -z "$DOVIS" -o "$PKG_COVERAGE" ]; then pip install coverage; fi
## getting test deps
- pip install -e .[test]
script:
- shyaml --version
- bin/test
after_success:
- "bash <(curl -s https://codecov.io/bash) #dovis: ignore"
- |
if [ "$DOVIS" -a -d "$ARTIFACT_DIR" ]; then
cp ".coverage" "$ARTIFACT_DIR"
echo "$PWD" > "$ARTIFACT_DIR/cover_path"
fi
## Ignored by Travis, but used internally to check packaging
dist_check:
options:
exclude:
- ["v:3.6", "pkg:old"] ## old version is breaking python 3.6 pkg_resources
- ["v:3.7", "pkg:old"] ## old version is breaking python 3.7 pkg_resources
tests:
- label: install
matrix:
'yes':
- label: venv
matrix:
'on': |
pip install virtualenv
virtualenv /tmp/virtualenv
. /tmp/virtualenv/bin/activate
'off': |
true
- label: pkg
matrix:
old: |
## version 10 introduce a bug with d2to1
pip install setuptools==9.1
## some ``python setup.py`` black magic do not work with d2to1 and pip ``6.0.7``
pip install pip==1.5.6
docker: |
## Using the versions of python docker images
true
latest: |
## Using the last version of pip and setuptools
pip install pip --upgrade
pip install setuptools --upgrade
- label: method
matrix:
setup: python setup.py install
pip: pip install .
pip+git: pip install "git+file://$PWD"
dist:
dist_files:
pip install "$DIST_FILE"
- |
pip show -f $(./autogen.sh --get-name)
pip list
'no':
- |
ln -sf $PWD/$(./autogen.sh --get-name) /usr/local/bin/
pip install pyyaml
export PYTHONPATH="$PWD"
touch /tmp/not-installed
- |
SRC=$PWD
cd /tmp
cat <<EOF | shyaml get-value c.d
a: b
c:
d: 1
EOF
- |
cd /tmp
echo PYTHONPATH: "${PYTHONPATH:-<empty>}"
python -c 'import shyaml'
- |
[ -e /tmp/not-installed ] || {
cd "$SRC"
pip uninstall -y $(./autogen.sh --get-name)
}