Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1773)

Unified Diff: autoupdate_unittest.py

Issue 5297002: --archive_dir will now serve existing update.gz (Closed) Base URL: http://git.chromium.org/git/dev-util.git@master
Patch Set: Code review fixes. Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « autoupdate.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: autoupdate_unittest.py
diff --git a/autoupdate_unittest.py b/autoupdate_unittest.py
index 0aaa5d373ceed95afa00606976d304c7c354ed12..029f1c9302e380661a33fd86ec167e0a781758eb 100755
--- a/autoupdate_unittest.py
+++ b/autoupdate_unittest.py
@@ -124,32 +124,6 @@ class AutoupdateTest(mox.MoxTestBase):
self.assertEqual(au_mock.HandleUpdatePing(test_data), self.payload)
self.mox.VerifyAll()
- def testHandleUpdatePingForArchivedBuild(self):
- self.mox.StubOutWithMock(autoupdate.Autoupdate, 'GenerateImageFromZip')
-
- test_data = _TEST_REQUEST % self.test_dict
-
- autoupdate.Autoupdate.GenerateImageFromZip(
- self.static_image_dir).AndReturn('update.gz')
- autoupdate.Autoupdate._GetHash(os.path.join(
- self.static_image_dir, 'update.gz')).AndReturn(self.hash)
- autoupdate.Autoupdate._GetSHA256(os.path.join(
- self.static_image_dir, 'update.gz')).AndReturn(self.sha256)
- autoupdate.Autoupdate._GetSize(os.path.join(
- self.static_image_dir, 'update.gz')).AndReturn(self.size)
- autoupdate.Autoupdate.GetUpdatePayload(
- self.hash, self.sha256, self.size,
- 'http://%s/static/archive/update.gz' % self.hostname,
- False).AndReturn(
- self.payload)
-
- self.mox.ReplayAll()
- au_mock = self._DummyAutoupdateConstructor()
- au_mock.serve_only = True
- au_mock.static_urlbase = 'http://%s/static/archive' % self.hostname
- self.assertEqual(au_mock.HandleUpdatePing(test_data), self.payload)
- self.mox.VerifyAll()
-
if __name__ == '__main__':
unittest.main()
« no previous file with comments | « autoupdate.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698