Exemple #1
0
 def test_logfiles_to_copy_size_diff(self):
     src = {RdsLogFile('foo', '', size=123)}
     dst = {S3LogFile('foo', '', '', size=0)}
     self.assertEqual({LogFile('foo', size=123)},
                      LogFileHandler.logfiles_to_copy(src, dst))
Exemple #2
0
 def test_logfiles_to_copy_empty_dst(self):
     dst = set()
     src = {RdsLogFile('foo', '')}
     self.assertEqual(src, LogFileHandler.logfiles_to_copy(src, dst))
     src = {RdsLogFile('foo', ''), RdsLogFile('bar', '')}
     self.assertEqual(src, LogFileHandler.logfiles_to_copy(src, dst))
Exemple #3
0
 def test_logfiles_to_copy_new_files_on_src_old_on_dst(self):
     src = {RdsLogFile('foo', ''), RdsLogFile('bar', '')}
     dst = {S3LogFile('foo', '', ''), S3LogFile('xyz', '', '')}
     self.assertEqual({LogFile('bar')},
                      LogFileHandler.logfiles_to_copy(src, dst))
Exemple #4
0
 def test_logfiles_to_copy_empty_src(self):
     src = set()
     dst = set()
     self.assertEqual(set(), LogFileHandler.logfiles_to_copy(src, dst))
     dst = {S3LogFile('foo', '', '')}
     self.assertEqual(set(), LogFileHandler.logfiles_to_copy(src, dst))