def test_execute(self): application = EnhydrisCacheApp() application.read_command_line() application.read_configuration() application.setup_logger() # Check that the two files don't exist yet self.assertFalse(os.path.exists(os.path.join(self.tempdir, 'file1'))) self.assertFalse(os.path.exists(os.path.join(self.tempdir, 'file2'))) application.execute() # Check that it has created two files self.assertTrue(os.path.exists(os.path.join(self.tempdir, 'file1'))) self.assertTrue(os.path.exists(os.path.join(self.tempdir, 'file2')))
def test_correct_configuration(self): application = EnhydrisCacheApp() application.run(dry=True)