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

Unified Diff: test/ios/gyptest-app-ios.py

Issue 825453002: Convert plist and strings to binary for iOS. (Closed) Base URL: https://chromium.googlesource.com/external/gyp.git@master
Patch Set: Remove blank line Created 5 years, 9 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 | « test/ios/app-bundle/test.gyp ('k') | test/mac/gyptest-app.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/ios/gyptest-app-ios.py
diff --git a/test/ios/gyptest-app-ios.py b/test/ios/gyptest-app-ios.py
index 37afbfe0e44329f0007e25c6c69d1f347b871189..f5fd5f93f7424f444a67f4e2115a9bf28cfcd44c 100755
--- a/test/ios/gyptest-app-ios.py
+++ b/test/ios/gyptest-app-ios.py
@@ -10,8 +10,22 @@ Verifies that ios app bundles are built correctly.
import TestGyp
+import subprocess
import sys
+def CheckFileXMLPropertyList(file):
+ output = subprocess.check_output(['file', file])
+ # The double space after XML is intentional.
+ if not 'XML document text' in output:
+ print 'File: Expected XML document text, got %s' % output
+ test.fail_test()
+
+def CheckFileBinaryPropertyList(file):
+ output = subprocess.check_output(['file', file])
+ if not 'Apple binary property list' in output:
+ print 'File: Expected Apple binary property list, got %s' % output
+ test.fail_test()
+
if sys.platform == 'darwin':
test = TestGyp.TestGyp(formats=['xcode', 'ninja'])
@@ -26,10 +40,21 @@ if sys.platform == 'darwin':
# Info.plist
info_plist = test.built_file_path('Test App Gyp.app/Info.plist',
chdir='app-bundle')
+ test.built_file_must_exist(info_plist)
+ CheckFileBinaryPropertyList(info_plist)
+
+ # XML Info.plist
+ info_plist = test.built_file_path('Test App Gyp XML.app/Info.plist',
+ chdir='app-bundle')
+ CheckFileXMLPropertyList(info_plist)
+
# Resources
- test.built_file_must_exist(
+ strings_file = test.built_file_path(
'Test App Gyp.app/English.lproj/InfoPlist.strings',
chdir='app-bundle')
+ test.built_file_must_exist(strings_file)
+ CheckFileBinaryPropertyList(strings_file)
+
test.built_file_must_exist(
'Test App Gyp.app/English.lproj/MainMenu.nib',
chdir='app-bundle')
« no previous file with comments | « test/ios/app-bundle/test.gyp ('k') | test/mac/gyptest-app.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698