예제 #1
0
 def test_up_to_date(self):
     distribution = RemoteDistribution(
         self.mock_repo(),
         '../../packages/source/p/pkgsync/pkgsync-0.1.0.tar.gz#md5=%s' % self.empty_digest,
         'pkgsync',
     )
     self.assertEqual(RemoteDistribution.diff([distribution], [distribution]), [])
예제 #2
0
 def test_tgz_and_zip(self):
     repo = self.mock_repo()
     tgz_d = RemoteDistribution(
         repo,
         '../../packages/source/p/pkgsync/pkgsync-0.1.0.tar.gz#md5=%s' % self.empty_digest,
         'pkgsync',
     )
     zip_d = RemoteDistribution(
         repo,
         '../../packages/source/p/pkgsync/pkgsync-0.1.0.zip#md5=%s' % self.empty_digest,
         'pkgsync',
     )
     self.assertEqual(RemoteDistribution.diff([zip_d, tgz_d], [tgz_d]), [zip_d])
예제 #3
0
 def test_empty_diff(self):
     self.assertEqual(RemoteDistribution.diff([], []), [])