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

Unified Diff: native_client_sdk/src/build_tools/tests/sdktools_commands_test.py

Issue 11946002: [NaCl SDK] Fix update issues in sdk_tools. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: feedback Created 7 years, 11 months 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 | « native_client_sdk/src/build_tools/sdk_tools/command/update.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: native_client_sdk/src/build_tools/tests/sdktools_commands_test.py
diff --git a/native_client_sdk/src/build_tools/tests/sdktools_commands_test.py b/native_client_sdk/src/build_tools/tests/sdktools_commands_test.py
index 113ec9d01d40b4510c8befe579409fdd7db79660..25c10a08ea16eb2afb0bf55762e427bcca15d1e4 100755
--- a/native_client_sdk/src/build_tools/tests/sdktools_commands_test.py
+++ b/native_client_sdk/src/build_tools/tests/sdktools_commands_test.py
@@ -222,6 +222,28 @@ class TestCommands(SdkToolsTestCase):
output = self._Run(['update', 'foobar'])
self.assertTrue('unknown bundle' in output)
+ def testUpdateRecommended(self):
+ """The update command should update only recommended bundles when run
+ without args.
+ """
+ bundle = self._AddDummyBundle(self.manifest, 'pepper_26')
+ bundle.recommended = 'yes'
+ self._WriteManifest()
+ output = self._Run(['update'])
+ self.assertTrue(os.path.exists(
+ os.path.join(self.basedir, 'nacl_sdk', 'pepper_26', 'dummy.txt')))
+
+ def testUpdateCanary(self):
+ """The update command should create the correct directory name for repath'd
+ bundles.
+ """
+ bundle = self._AddDummyBundle(self.manifest, 'pepper_26')
+ bundle.name = 'pepper_canary'
+ self._WriteManifest()
+ output = self._Run(['update'])
+ self.assertTrue(os.path.exists(
+ os.path.join(self.basedir, 'nacl_sdk', 'pepper_canary', 'dummy.txt')))
+
if __name__ == '__main__':
- sys.exit(unittest.main())
+ unittest.main()
« no previous file with comments | « native_client_sdk/src/build_tools/sdk_tools/command/update.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698