Skip to content

Commit afaddaf

Browse files
committed
Add tests to Travis configuration
1 parent 8e55b95 commit afaddaf

File tree

1 file changed

+17
-7
lines changed

1 file changed

+17
-7
lines changed

.travis.yml

+17-7
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,21 @@
11
language: python
22
sudo: required
3+
env:
4+
- WHAT=webpage
5+
- WHAT=test PROG=sed
6+
- WHAT=test PROG=vim
37
python:
48
- "2.7"
5-
install:
6-
- sudo apt-get update
7-
- sudo apt-get install oracle-java8-installer
8-
- sudo update-java-alternatives -s java-8-oracle
9-
- pip install html5validator
10-
script:
11-
- html5validator --show-warnings
9+
install: |
10+
if [ $WHAT = webpage ]; then
11+
sudo apt-get update
12+
sudo apt-get install oracle-java8-installer
13+
sudo update-java-alternatives -s java-8-oracle
14+
pip install html5validator
15+
fi
16+
script: |
17+
if [ $WHAT = webpage ]; then
18+
html5validator --show-warnings
19+
else
20+
tests/test_$PROG.sh
21+
fi

0 commit comments

Comments
 (0)