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

Unified Diff: net/data/verify_certificate_chain_unittest/rebase-errors.py

Issue 2337373003: Add error details to ParseCertificate test data. (Closed)
Patch Set: rename Created 4 years, 3 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
Index: net/data/verify_certificate_chain_unittest/rebase-errors.py
diff --git a/net/data/verify_certificate_chain_unittest/rebase-errors.py b/net/data/verify_certificate_chain_unittest/rebase-errors.py
index 079aa40e746c8ebbda23a45a16451afb364847c5..61d06816fdc8dd80ed0be467c54cad72bbf40e40 100755
--- a/net/data/verify_certificate_chain_unittest/rebase-errors.py
+++ b/net/data/verify_certificate_chain_unittest/rebase-errors.py
@@ -88,11 +88,10 @@ def fixup_pem_file(path, actual_errors):
m = prog.search(contents)
if not m:
- print "Couldn't find ERRORS block in %s" % (path)
- return
-
- contents = replace_string(contents, m.start(1), m.end(1),
- common.text_data_to_pem('ERRORS', actual_errors))
+ contents += '\n' + common.text_data_to_pem('ERRORS', actual_errors)
+ else:
+ contents = replace_string(contents, m.start(1), m.end(1),
+ common.text_data_to_pem('ERRORS', actual_errors))
# Update the file.
write_string_to_file(contents, path)

Powered by Google App Engine
This is Rietveld 408576698