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

Side by Side Diff: content/browser/tracing/tracing_controller_browsertest.cc

Issue 2533333002: Fix TracingControllerTest.NotWhitelistedMetadataStripped
Patch Set: Created 4 years 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 unified diff | Download patch
« no previous file with comments | « base/trace_event/trace_log.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/public/browser/tracing_controller.h" 5 #include "content/public/browser/tracing_controller.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/files/file_util.h" 10 #include "base/files/file_util.h"
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after
377 std::string os_name; 377 std::string os_name;
378 last_metadata()->GetString("os-name", &os_name); 378 last_metadata()->GetString("os-name", &os_name);
379 EXPECT_TRUE(os_name.length() > 0); 379 EXPECT_TRUE(os_name.length() > 0);
380 std::string cpu_brand; 380 std::string cpu_brand;
381 last_metadata()->GetString("cpu-brand", &cpu_brand); 381 last_metadata()->GetString("cpu-brand", &cpu_brand);
382 EXPECT_TRUE(cpu_brand.length() > 0); 382 EXPECT_TRUE(cpu_brand.length() > 0);
383 } 383 }
384 384
385 // TODO(crbug.com/642991) Disabled for flakiness. 385 // TODO(crbug.com/642991) Disabled for flakiness.
386 IN_PROC_BROWSER_TEST_F(TracingControllerTest, 386 IN_PROC_BROWSER_TEST_F(TracingControllerTest,
387 DISABLED_NotWhitelistedMetadataStripped) { 387 NotWhitelistedMetadataStripped) {
388 TestStartAndStopTracingStringWithFilter(); 388 TestStartAndStopTracingStringWithFilter();
389 // Check that a number of important keys exist in the metadata dictionary. 389 // Check that a number of important keys exist in the metadata dictionary.
390 EXPECT_TRUE(last_metadata() != NULL); 390 EXPECT_TRUE(last_metadata() != NULL);
391 std::string cpu_brand; 391 std::string cpu_brand;
392 last_metadata()->GetString("cpu-brand", &cpu_brand); 392 last_metadata()->GetString("cpu-brand", &cpu_brand);
393 EXPECT_TRUE(cpu_brand.length() > 0); 393 EXPECT_TRUE(cpu_brand.length() > 0);
394 EXPECT_TRUE(cpu_brand != "__stripped__"); 394 EXPECT_TRUE(cpu_brand != "__stripped__");
395 std::string network_type; 395 std::string network_type;
396 last_metadata()->GetString("network-type", &network_type); 396 last_metadata()->GetString("network-type", &network_type);
397 EXPECT_TRUE(network_type.length() > 0); 397 EXPECT_TRUE(network_type.length() > 0);
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 444
445 TracingController* controller = TracingController::GetInstance(); 445 TracingController* controller = TracingController::GetInstance();
446 EXPECT_TRUE(controller->StartTracing( 446 EXPECT_TRUE(controller->StartTracing(
447 TraceConfig(), 447 TraceConfig(),
448 TracingController::StartTracingDoneCallback())); 448 TracingController::StartTracingDoneCallback()));
449 EXPECT_TRUE(controller->StopTracing(NULL)); 449 EXPECT_TRUE(controller->StopTracing(NULL));
450 base::RunLoop().RunUntilIdle(); 450 base::RunLoop().RunUntilIdle();
451 } 451 }
452 452
453 } // namespace content 453 } // namespace content
OLDNEW
« no previous file with comments | « base/trace_event/trace_log.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698