Ejemplo n.º 1
0
 def test_simdir(self):
     x = io.simdir()
     self.assertTrue(x is not None)
     night = '20150101'
     x = io.simdir(night)
     self.assertTrue(x.endswith(night))
     x = io.simdir(night, mkdir=True)
     self.assertTrue(os.path.exists(x))
Ejemplo n.º 2
0
 def test_simdir(self):
     x = io.simdir()
     self.assertTrue(x is not None)
     night = '20150101'
     x = io.simdir(night)
     self.assertTrue(x.endswith(night))
     x = io.simdir(night, mkdir=True)
     self.assertTrue(os.path.exists(x))
Ejemplo n.º 3
0
    def test_simdir(self):
        x = io.simdir()
        self.assertTrue(x is not None)
        night = '20150101'
        expid = 123
        x = io.simdir(night, expid)
        self.assertTrue(x.endswith(str(expid)))
        x = io.simdir(int(night), expid)
        self.assertTrue(x.endswith(str(expid)))

        #- If providing night, must also provide expid
        with self.assertRaises(ValueError):
            x = io.simdir(night, mkdir=True)
Ejemplo n.º 4
0
    def test_simdir(self):
        x = io.simdir()
        self.assertTrue(x is not None)
        night = '20150101'
        expid = 123
        x = io.simdir(night, expid)
        self.assertTrue(x.endswith(str(expid)))
        x = io.simdir(int(night), expid)
        self.assertTrue(x.endswith(str(expid)))

        #- If providing night, must also provide expid
        with self.assertRaises(ValueError):
            x = io.simdir(night, mkdir=True)