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

Side by Side Diff: net/cookies/cookie_monster_perftest.cc

Issue 2748073003: Run net_perftests on Linux perf bots (Closed)
Patch Set: rebased Created 3 years, 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | testing/buildbot/chromium.perf.json » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <algorithm> 5 #include <algorithm>
6 #include <memory> 6 #include <memory>
7 7
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 getCookiesCallback.GetCookies(cm.get(), GURL(kGoogleURL)); 147 getCookiesCallback.GetCookies(cm.get(), GURL(kGoogleURL));
148 } 148 }
149 timer2.Done(); 149 timer2.Done();
150 150
151 base::PerfTimeLogger timer3("Cookie_monster_deleteall_single_host"); 151 base::PerfTimeLogger timer3("Cookie_monster_deleteall_single_host");
152 cm->DeleteAllAsync(CookieMonster::DeleteCallback()); 152 cm->DeleteAllAsync(CookieMonster::DeleteCallback());
153 base::RunLoop().RunUntilIdle(); 153 base::RunLoop().RunUntilIdle();
154 timer3.Done(); 154 timer3.Done();
155 } 155 }
156 156
157 TEST_F(CookieMonsterTest, TestAddCookieOnManyHosts) { 157 // TODO(xunjieli): Renable after crbug.com/730000 is fixed.
158 TEST_F(CookieMonsterTest, DISABLED_TestAddCookieOnManyHosts) {
158 std::unique_ptr<CookieMonster> cm(new CookieMonster(nullptr, nullptr)); 159 std::unique_ptr<CookieMonster> cm(new CookieMonster(nullptr, nullptr));
159 std::string cookie(kCookieLine); 160 std::string cookie(kCookieLine);
160 std::vector<GURL> gurls; // just wanna have ffffuunnn 161 std::vector<GURL> gurls; // just wanna have ffffuunnn
161 for (int i = 0; i < kNumCookies; ++i) { 162 for (int i = 0; i < kNumCookies; ++i) {
162 gurls.push_back(GURL(base::StringPrintf("https://a%04d.izzle", i))); 163 gurls.push_back(GURL(base::StringPrintf("https://a%04d.izzle", i)));
163 } 164 }
164 165
165 SetCookieCallback setCookieCallback; 166 SetCookieCallback setCookieCallback;
166 167
167 // Add a cookie on a bunch of host 168 // Add a cookie on a bunch of host
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 setCookieCallback.SetCookie(cm.get(), gurl, cookie_line); 383 setCookieCallback.SetCookie(cm.get(), gurl, cookie_line);
383 384
384 base::PerfTimeLogger timer((std::string("GC_") + test_case.name).c_str()); 385 base::PerfTimeLogger timer((std::string("GC_") + test_case.name).c_str());
385 for (int i = 0; i < kNumCookies; i++) 386 for (int i = 0; i < kNumCookies; i++)
386 setCookieCallback.SetCookie(cm.get(), gurl, cookie_line); 387 setCookieCallback.SetCookie(cm.get(), gurl, cookie_line);
387 timer.Done(); 388 timer.Done();
388 } 389 }
389 } 390 }
390 391
391 } // namespace net 392 } // namespace net
OLDNEW
« no previous file with comments | « no previous file | testing/buildbot/chromium.perf.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698