| Index: components/offline_pages/background/request_coordinator_unittest.cc
|
| diff --git a/components/offline_pages/background/request_coordinator_unittest.cc b/components/offline_pages/background/request_coordinator_unittest.cc
|
| index 11cd76855e29238678c673c8345ecd41d18fc84f..b1b1f929d7918bb61cf407f44f8344b7483da8a6 100644
|
| --- a/components/offline_pages/background/request_coordinator_unittest.cc
|
| +++ b/components/offline_pages/background/request_coordinator_unittest.cc
|
| @@ -401,7 +401,10 @@ TEST_F(RequestCoordinatorTest, StartProcessingWithNoRequests) {
|
|
|
| TEST_F(RequestCoordinatorTest, StartProcessingWithRequestInProgress) {
|
| // Put the request on the queue.
|
| - EXPECT_TRUE(coordinator()->SavePageLater(kUrl1, kClientId1, kUserRequested));
|
| + EXPECT_TRUE(
|
| + coordinator()->SavePageLater(
|
| + kUrl1, kClientId1, kUserRequested,
|
| + RequestCoordinator::RequestAvailability::ENABLED_FOR_OFFLINER) != 0);
|
|
|
| // Set up for the call to StartProcessing by building arguments.
|
| DeviceConditions device_conditions(
|
| @@ -424,7 +427,10 @@ TEST_F(RequestCoordinatorTest, StartProcessingWithRequestInProgress) {
|
| }
|
|
|
| TEST_F(RequestCoordinatorTest, SavePageLater) {
|
| - EXPECT_TRUE(coordinator()->SavePageLater(kUrl1, kClientId1, kUserRequested));
|
| + EXPECT_TRUE(
|
| + coordinator()->SavePageLater(
|
| + kUrl1, kClientId1, kUserRequested,
|
| + RequestCoordinator::RequestAvailability::ENABLED_FOR_OFFLINER) != 0);
|
|
|
| // Expect that a request got placed on the queue.
|
| coordinator()->queue()->GetRequests(
|
| @@ -1030,7 +1036,10 @@ TEST_F(RequestCoordinatorTest,
|
| SavePageStartsProcessingWhenConnectedAndNotLowEndDevice) {
|
| SetEffectiveConnectionTypeForTest(
|
| net::EffectiveConnectionType::EFFECTIVE_CONNECTION_TYPE_3G);
|
| - EXPECT_TRUE(coordinator()->SavePageLater(kUrl1, kClientId1, kUserRequested));
|
| + EXPECT_TRUE(
|
| + coordinator()->SavePageLater(
|
| + kUrl1, kClientId1, kUserRequested,
|
| + RequestCoordinator::RequestAvailability::ENABLED_FOR_OFFLINER) != 0);
|
| PumpLoop();
|
|
|
| // Now whether processing triggered immediately depends on whether test
|
| @@ -1043,7 +1052,10 @@ TEST_F(RequestCoordinatorTest,
|
| }
|
|
|
| TEST_F(RequestCoordinatorTest, SavePageDoesntStartProcessingWhenDisconnected) {
|
| - EXPECT_TRUE(coordinator()->SavePageLater(kUrl1, kClientId1, kUserRequested));
|
| + EXPECT_TRUE(
|
| + coordinator()->SavePageLater(
|
| + kUrl1, kClientId1, kUserRequested,
|
| + RequestCoordinator::RequestAvailability::ENABLED_FOR_OFFLINER) != 0);
|
| PumpLoop();
|
| EXPECT_FALSE(is_busy());
|
| }
|
| @@ -1052,7 +1064,10 @@ TEST_F(RequestCoordinatorTest,
|
| SavePageDoesntStartProcessingWhenPoorlyConnected) {
|
| SetEffectiveConnectionTypeForTest(
|
| net::EffectiveConnectionType::EFFECTIVE_CONNECTION_TYPE_SLOW_2G);
|
| - EXPECT_TRUE(coordinator()->SavePageLater(kUrl1, kClientId1, kUserRequested));
|
| + EXPECT_TRUE(
|
| + coordinator()->SavePageLater(
|
| + kUrl1, kClientId1, kUserRequested,
|
| + RequestCoordinator::RequestAvailability::ENABLED_FOR_OFFLINER) != 0);
|
| PumpLoop();
|
| EXPECT_FALSE(is_busy());
|
| }
|
|
|