Esempio n. 1
0
 def test_is_css(self):
     """
     Read files via obspy.core.stream.read function.
     """
     # 1
     assert (_is_css(self.filename_css))
     # check that empty files are not recognized as CSS
     with NamedTemporaryFile() as tf:
         tempfile = tf.name
         fh = open(tempfile, "wb")
         fh.close()
         assert (not _is_css(tempfile))
Esempio n. 2
0
 def test_is_css(self):
     """
     Read files via obspy.core.stream.read function.
     """
     # 1
     assert(_is_css(self.filename_css))
     # check that empty files are not recognized as CSS
     with NamedTemporaryFile() as tf:
         tempfile = tf.name
         fh = open(tempfile, "wb")
         fh.close()
         assert(not _is_css(tempfile))
Esempio n. 3
0
 def test_is_not_this_format_core(self):
     # check that NNSA files are not recognized as CSS
     assert (not _is_css(self.filename_nnsa))
     # check that CSS file is not recognized as NNSA_KB_CORE
     assert (not _is_nnsa_kb_core(self.filename_css))