Пример #1
0
 def test_log_path_logfile_overrides_logdir(self):
     self.flags(logdir='/some/other/path',
                logfile='/some/path/foo-bar.log')
     self.assertEquals(log._get_log_file_path(binary='foo-bar'),
                      '/some/path/foo-bar.log')
Пример #2
0
 def test_log_path_logfile(self):
     self.flags(logfile='/some/path/foo-bar.log')
     self.assertEquals(log._get_log_file_path(binary='foo-bar'),
                      '/some/path/foo-bar.log')
Пример #3
0
 def test_log_path_none(self):
     self.flags(logdir=None, logfile=None)
     self.assertTrue(log._get_log_file_path(binary='foo-bar') is None)
Пример #4
0
 def test_log_path_logfile_overrides_logdir(self):
     self.flags(logdir='/some/other/path', logfile='/some/path/foo-bar.log')
     self.assertEquals(log._get_log_file_path(binary='foo-bar'),
                       '/some/path/foo-bar.log')
Пример #5
0
 def test_log_path_none(self):
     self.flags(logdir=None, logfile=None)
     self.assertTrue(log._get_log_file_path(binary='foo-bar') is None)
Пример #6
0
 def test_log_path_logfile(self):
     self.flags(logfile='/some/path/foo-bar.log')
     self.assertEquals(log._get_log_file_path(binary='foo-bar'),
                       '/some/path/foo-bar.log')
Пример #7
0
 def test_log_path_logfile_overrides_logdir(self):
     self.flags(logdir="/some/other/path", logfile="/some/path/foo-bar.log")
     self.assertEquals(log._get_log_file_path(binary="foo-bar"), "/some/path/foo-bar.log")
Пример #8
0
 def test_log_path_logfile(self):
     self.flags(logfile="/some/path/foo-bar.log")
     self.assertEquals(log._get_log_file_path(binary="foo-bar"), "/some/path/foo-bar.log")