diff --git a/.travis.yml b/.travis.yml index 21ba88d..0da8c1d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,16 @@ language: python sudo: false cache: pip +matrix: + include: + - python: 2.7 + env: TOXENV=py27 + - python: 3.4 + env: TOXENV=py34 + - python: 3.5 + env: TOXENV=py35 before_install: - pip install tox # command to run tests script: - - tox \ No newline at end of file + - tox diff --git a/escpos/escpos.py b/escpos/escpos.py index a5bac17..467cf4d 100644 --- a/escpos/escpos.py +++ b/escpos/escpos.py @@ -83,7 +83,7 @@ class Escpos(object): pbuffer = b'' self._raw(S_RASTER_N) - pbuffer = "%02X%02X%02X%02X" % (((size[0]/size[1])/8), 0, size[1] & 0xff, size[1] >> 8) + pbuffer = "%02X%02X%02X%02X" % (((size[0]//size[1])//8), 0, size[1] & 0xff, size[1] >> 8) self._raw(binascii.unhexlify(pbuffer)) pbuffer = "" diff --git a/tox.ini b/tox.ini index 0a56f96..c7460c5 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = py27, py34 +envlist = py27, py34, py35 [testenv] deps = nose