summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTushar Gohad <tushar.gohad@intel.com>2015-03-09 11:24:03 -0700
committerTushar Gohad <tushar.gohad@intel.com>2015-03-09 11:24:37 -0700
commita2275fd61df30f1f717db6c1d45acce46057db27 (patch)
tree7ba6cc73d9878f4cd05b9c41d54377166363fe10
parent3d7a0d996edfe9e830a523f3e2804125d9493b18 (diff)
downloadpyeclib-a2275fd61df30f1f717db6c1d45acce46057db27.tar.gz
Remove references to skipIf (breaks on py2.6)
-rw-r--r--test/test_pyeclib_c.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/test/test_pyeclib_c.py b/test/test_pyeclib_c.py
index d1651b9..ddd7e27 100644
--- a/test/test_pyeclib_c.py
+++ b/test/test_pyeclib_c.py
@@ -26,7 +26,6 @@ from string import ascii_letters
import tempfile
import time
import unittest
-from unittest import skipIf
import pyeclib_c
from pyeclib.ec_iface import PyECLib_EC_Types
@@ -290,9 +289,11 @@ class TestPyECLib(unittest.TestCase):
return format(throughput, '.10g')
- @skipIf("flat_xor_hd" not in _available_backends,
- "\nxor backend is not available in your enviromnet")
def test_xor_code(self):
+ if "flat_xor_hd" not in _available_backends:
+ print("xor backend is not available in your enviromnet, skipping test")
+ return
+
for (ec_type, k, m, hd) in self.xor_types:
print(("\nRunning tests for %s k=%d, m=%d, hd=%d" % (ec_type, k, m, hd)))
@@ -319,9 +320,10 @@ class TestPyECLib(unittest.TestCase):
print("Reconstruct (%s): %s" %
(size_str, self.get_throughput(avg_time, size_str)))
- @skipIf("shss" not in _available_backends,
- "\nshss backend is not available in your enviromnet")
def test_shss(self):
+ if "shss" not in _available_backends:
+ print("shss backend is not available in your enviromnet, skipping test")
+ return
for (ec_type, k, m) in self.shss:
print(("\nRunning tests for %s k=%d, m=%d" % (ec_type, k, m)))