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

Side by Side Diff: content/renderer/scheduler/resource_dispatch_throttler_unittest.cc

Issue 2969463003: Move resource_request.h to content/public/common. (Closed)
Patch Set: Merge Created 3 years, 5 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/renderer/scheduler/resource_dispatch_throttler.h" 5 #include "content/renderer/scheduler/resource_dispatch_throttler.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/macros.h" 13 #include "base/macros.h"
14 #include "base/memory/ptr_util.h" 14 #include "base/memory/ptr_util.h"
15 #include "content/common/resource_messages.h" 15 #include "content/common/resource_messages.h"
16 #include "content/common/resource_request.h" 16 #include "content/public/common/resource_request.h"
17 #include "testing/gtest/include/gtest/gtest.h" 17 #include "testing/gtest/include/gtest/gtest.h"
18 #include "third_party/WebKit/public/platform/scheduler/test/fake_renderer_schedu ler.h" 18 #include "third_party/WebKit/public/platform/scheduler/test/fake_renderer_schedu ler.h"
19 19
20 namespace content { 20 namespace content {
21 namespace { 21 namespace {
22 22
23 const uint32_t kRequestsPerFlush = 4; 23 const uint32_t kRequestsPerFlush = 4;
24 const double kFlushPeriodSeconds = 1.f / 60; 24 const double kFlushPeriodSeconds = 1.f / 60;
25 const int kRoutingId = 1; 25 const int kRoutingId = 1;
26 26
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
410 EXPECT_EQ(priority_msg.type(), ResourceHostMsg_DidChangePriority::ID); 410 EXPECT_EQ(priority_msg.type(), ResourceHostMsg_DidChangePriority::ID);
411 EXPECT_EQ(cancel_msg.type(), ResourceHostMsg_CancelRequest::ID); 411 EXPECT_EQ(cancel_msg.type(), ResourceHostMsg_CancelRequest::ID);
412 412
413 EXPECT_EQ(GetRequestId(request_msg), GetRequestId(priority_msg)); 413 EXPECT_EQ(GetRequestId(request_msg), GetRequestId(priority_msg));
414 EXPECT_EQ(GetRequestId(request_msg) - 1, GetRequestId(cancel_msg)); 414 EXPECT_EQ(GetRequestId(request_msg) - 1, GetRequestId(cancel_msg));
415 } 415 }
416 EXPECT_FALSE(FlushScheduled()); 416 EXPECT_FALSE(FlushScheduled());
417 } 417 }
418 418
419 } // namespace content 419 } // namespace content
OLDNEW
« no previous file with comments | « content/public/common/service_worker_modes.h ('k') | content/renderer/service_worker/service_worker_context_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698