Permalink
Browse files

Ignore the BiopythonExperimentalWarning in test_Motif.py

  • Loading branch information...
1 parent f74e39d commit 4cd70fcd27e6eab86682be702883432405c546f4 Michiel de Hoon committed Nov 25, 2012
Showing with 6 additions and 0 deletions.
  1. +6 −0 Tests/test_Motif.py
View
@@ -7,9 +7,12 @@
import os
import unittest
+
from Bio import Motif
from Bio.Seq import Seq
+
+
class MotifTestsBasic(unittest.TestCase):
def setUp(self):
self.PFMin = open("Motif/SRF.pfm")
@@ -31,6 +34,9 @@ def tearDown(self):
def test_alignace_parsing(self):
"""Test if Motif can parse AlignAce output files.
"""
+ import warnings
+ from Bio import BiopythonExperimentalWarning
+ warnings.simplefilter('ignore', BiopythonExperimentalWarning)
from Bio.Alphabet import IUPAC
from Bio.Motif import AlignAce
handle = open("Motif/alignace.out")

2 comments on commit 4cd70fc

Owner

peterjc replied Nov 25, 2012

I was wondering if we should put this filter in run_tests.py, rather than every separate test_XXX.py - although the later approach is useful for testing individual modules on their own. What do you think?

Contributor

mdehoon replied Nov 26, 2012

I would leave this in the separate text_XXX.py, because oftentimes you just want to run one test, and it should then behave the same as when somebody runs run_tests.py

Please sign in to comment.