Skip to content

Commit fe9666e

Browse files
committed
Test jsaone on Travis as well as more ijson configurations
1 parent 2a13bfd commit fe9666e

File tree

4 files changed

+65
-5
lines changed

4 files changed

+65
-5
lines changed

.travis.yml

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,34 @@ sudo: false
22
language: python
33
python:
44
- "2.6"
5-
- "2.7"
65
- "3.2"
76
- "3.3"
87
- "3.4"
9-
- "3.5"
108
matrix:
119
include:
1210
- python: 2.7
1311
env: TEST=slow
1412
- python: 3.5
1513
env: TEST=slow
14+
- python: 2.7
15+
env: STREAMING_BACKEND=ijson
16+
- python: 2.7
17+
env: STREAMING_BACKEND=ijson-yajl
18+
- python: 2.7
19+
env: STREAMING_BACKEND=ijson-yajl2
20+
- python: 2.7
21+
env: STREAMING_BACKEND=jsaone
22+
- python: 3.5
23+
env: STREAMING_BACKEND=ijson
24+
- python: 3.5
25+
env: STREAMING_BACKEND=ijson-yajl
26+
- python: 3.5
27+
env: STREAMING_BACKEND=ijson-yajl2
28+
- python: 3.5
29+
env: STREAMING_BACKEND=jsaone
1630
services:
1731
- redis-server
1832
install: >
19-
pip install -r requirements-dev.txt
33+
./tests/travis/setup.sh
2034
script: >
2135
./tests/travis/run.sh

requirements-dev.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
-r requirements.txt
2-
ijson
32
nose
43
unittest2

tests/travis/run.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22

33
set -e
44

5-
NOSETESTS=nosetests
5+
NOSETESTS="nosetests -v"
6+
7+
export LD_LIBRARY_PATH=/home/travis/local/lib
8+
9+
echo Streaming backend: `python -c 'import redisdl; print(redisdl.default_streaming_backend)'`
610

711
if test "$TEST" = slow; then
812
$NOSETESTS -a '!yajl2,slow'

tests/travis/setup.sh

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
#!/bin/sh
2+
3+
set -e
4+
5+
pip install -r requirements-dev.txt
6+
7+
case "$STREAMING_BACKEND" in
8+
ijson)
9+
pip install ijson;;
10+
ijson-yajl)
11+
pip install ijson
12+
git clone https://github.com/lloyd/yajl
13+
cd yajl
14+
git checkout 1.0.12
15+
./configure --prefix=/home/travis/local
16+
make
17+
make install
18+
;;
19+
ijson-yajl2)
20+
pip install ijson
21+
git clone https://github.com/lloyd/yajl
22+
cd yajl
23+
git checkout 2.0.0
24+
./configure --prefix=/home/travis/local
25+
make
26+
make install
27+
;;
28+
jsaone)
29+
# broken
30+
#pip install jsaone
31+
32+
pip install cython
33+
curl -o jsaone.tar.gz 'http://www.pietrobattiston.it/gitweb?p=jsaone.git;a=snapshot;h=master;sf=tgz'
34+
tar xf jsaone.tar.gz
35+
cd jsaone-master-*
36+
python setup.py install
37+
;;
38+
"")
39+
;;
40+
*)
41+
echo "Unknown streaming backend $STREAMING_BACKEND" 1>&2
42+
exit 10;;
43+
esac

0 commit comments

Comments
 (0)