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

Unified Diff: grit/format/policy_templates/writers/doc_writer_unittest.py

Issue 512733004: Fixed the example JSON strings for Windows and Linux. (Closed) Base URL: http://grit-i18n.googlecode.com/svn/trunk/
Patch Set: Created 6 years, 4 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 | « grit/format/policy_templates/writers/doc_writer.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: grit/format/policy_templates/writers/doc_writer_unittest.py
===================================================================
--- grit/format/policy_templates/writers/doc_writer_unittest.py (revision 173)
+++ grit/format/policy_templates/writers/doc_writer_unittest.py (working copy)
@@ -6,6 +6,7 @@
'''Unit tests for grit.format.policy_templates.writers.doc_writer'''
+import json
import os
import sys
if __name__ == '__main__':
@@ -688,14 +689,14 @@
},
}
self.writer._AddDictionaryExample(self.doc_root, policy)
- value = str(policy['example_value'])
+ value = json.dumps(policy['example_value']).replace('"', '"')
self.assertEquals(
self.doc_root.toxml(),
'<root>'
'<dl style="style_dd dl;">'
'<dt>Windows:</dt>'
'<dd style="style_.monospace;style_.pre;">MockKey\PolicyName = '
- '&quot;' + value + '&quot;'
+ + value +
'</dd>'
'<dt>Linux:</dt>'
'<dd style="style_.monospace;">PolicyName: ' + value + '</dd>'
« no previous file with comments | « grit/format/policy_templates/writers/doc_writer.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698