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

Unified Diff: components/feedback/anonymizer_tool_unittest.cc

Issue 2905723002: Anonymize UUIDs (Closed)
Patch Set: Created 3 years, 7 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 | « components/feedback/anonymizer_tool.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/feedback/anonymizer_tool_unittest.cc
diff --git a/components/feedback/anonymizer_tool_unittest.cc b/components/feedback/anonymizer_tool_unittest.cc
index b6247636caa9e1a5b79f3488935a87151452621a..c0b87540be0f3457463f987ae64867f4a48d2e2b 100644
--- a/components/feedback/anonymizer_tool_unittest.cc
+++ b/components/feedback/anonymizer_tool_unittest.cc
@@ -47,6 +47,22 @@ TEST_F(AnonymizerToolTest, Anonymize) {
// Make sure custom pattern anonymization is invoked.
EXPECT_EQ("Cell ID: '1'", AnonymizeCustomPatterns("Cell ID: 'A1B2'"));
+
+ // Make sure UUIDs are anonymized.
+ EXPECT_EQ(
+ "REQUEST localhost - - \"POST /printers/<UUID: 1> HTTP/1.1\" 200 291 "
+ "Create-Job successful-ok",
+ anonymizer_.Anonymize(
+ "REQUEST localhost - - \"POST /printers/"
+ "cb738a9f-6433-4d95-a81e-94e4ae0ed30b HTTP/1.1\" 200 291 Create-Job "
+ "successful-ok"));
+ EXPECT_EQ(
+ "REQUEST localhost - - \"POST /printers/<UUID: 2> HTTP/1.1\" 200 286 "
+ "Create-Job successful-ok",
+ anonymizer_.Anonymize(
+ "REQUEST localhost - - \"POST /printers/"
+ "d17188da-9cd3-44f4-b148-3e1d748a3b0f HTTP/1.1\" 200 286 Create-Job "
+ "successful-ok"));
}
TEST_F(AnonymizerToolTest, AnonymizeMACAddresses) {
« no previous file with comments | « components/feedback/anonymizer_tool.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698