Commits

Miki Tebeka committed 69339fb

check for snappy tests

  • Participants
  • Parent commits bcf0cb2

Comments (0)

Files changed (1)

tests/test_fastavro.py

 
 data_dir = join(abspath(dirname(__file__)), 'avro-files')
 
+try:
+    import snappy
+    has_snappy = True
+except ImportError:
+    has_snappy = False
+
 NO_DATA = set([
     'class org.apache.avro.tool.TestDataFileTools.zerojsonvalues.avro',
     'testDataFileMeta.avro',
 
 def test_fastavro():
     for filename in iglob(join(data_dir, '*.avro')):
+        if (not has_snappy) and ('snappy' in filename):
+            continue
         yield check, filename