示例#1
0
 def test03add_path(self):
     'QueueNull.add_path()'
     qn = QueueNull()
     data = 'foo'
     path = self.tempdir + '/foo.bar'
     fh = open(path, 'w')
     fh.write(data)
     fh.flush()
     fh.close()
     elem = qn.add_path(path)
     self.failIf(os.path.exists(path))
示例#2
0
 def test06count(self):
     'QueueNull.count()'
     qn = QueueNull()
     qn.add('foo1')
     assert qn.count() == 0
     qn.add('foo2')
     assert qn.count() == 0
示例#3
0
 def test08purge_oneDirOneElement(self):
     'QueueNull.purge() one directory & element'
     qn = QueueNull()
     qn.purge()
示例#4
0
 def test02add(self):
     'QueueNull.add()'
     data = 'foo bar'
     qn = QueueNull()
     elem = qn.add(data)
     assert elem == ""