From c25c8d724670ceb38c0c7a75274ccfe1be18ec02 Mon Sep 17 00:00:00 2001 From: INADA Naoki Date: Fri, 9 Jan 2015 03:41:52 +0900 Subject: [PATCH 1/3] Check extension module was compiled. --- .travis.yml | 2 +- tox.ini | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 29f1b7d..1bf6d4f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,4 +7,4 @@ install: - pip install tox cython - cython --cplus msgpack/_packer.pyx msgpack/_unpacker.pyx -script: "tox && MSGPACK_PUREPYTHON=x tox" +script: tox diff --git a/tox.ini b/tox.ini index 892684d..96b9fcb 100644 --- a/tox.ini +++ b/tox.ini @@ -1,8 +1,14 @@ [tox] -envlist = py26,py27,py32,py33,py34,pypy,pypy3 +envlist = {py26,py27,py32,py33,py34}-{c,pure},{pypy,pypy3}-pure + +[variants:pure] +setenv= + MSGPACK_PUREPYTHON=x [testenv] deps= pytest -commands=py.test test +commands= + c: python -c 'from msgpack import _packer, _unpacker' + pure: py.test test From ee0e435535800e51004e64d827d66bd8d30a1735 Mon Sep 17 00:00:00 2001 From: INADA Naoki Date: Fri, 9 Jan 2015 04:10:25 +0900 Subject: [PATCH 2/3] Fix compile error. --- msgpack/pack_template.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/msgpack/pack_template.h b/msgpack/pack_template.h index 2879bbd..5d1088f 100644 --- a/msgpack/pack_template.h +++ b/msgpack/pack_template.h @@ -712,7 +712,7 @@ static inline int msgpack_pack_raw_body(msgpack_packer* x, const void* b, size_t /* * Ext */ -static inline int msgpack_pack_ext(msgpack_packer* x, int8_t typecode, size_t l) +static inline int msgpack_pack_ext(msgpack_packer* x, char typecode, size_t l) { if (l == 1) { unsigned char buf[2]; From 715fcac6c6e2bf95a3d074ba186bd6fb106ee312 Mon Sep 17 00:00:00 2001 From: INADA Naoki Date: Fri, 9 Jan 2015 04:19:34 +0900 Subject: [PATCH 3/3] Fix tox --- tox.ini | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tox.ini b/tox.ini index 96b9fcb..8f10b15 100644 --- a/tox.ini +++ b/tox.ini @@ -9,6 +9,7 @@ setenv= deps= pytest +changedir=test commands= - c: python -c 'from msgpack import _packer, _unpacker' - pure: py.test test + c: python -c 'from msgpack import _packer, _unpacker' && py.test + pure: py.test