Commit ab07e400 authored by Victor Costan's avatar Victor Costan Committed by Commit Bot

test: Replace _TEST_CASE_ with _TEST_SUITE_ in /content/browser/service_worker.

Googletest is (at last) converging with industry-standard terminology
[1]. We previously called test suites "test cases", which was rather
confusing for folks coming from any other testing framework.

Chrome now has a googltest version that supports _TEST_SUITE_ macros
instead of _TEST_CASE_, so this CL cleans up some of the outdated usage.

[1] https://github.com/google/googletest/blob/master/googletest/docs/primer.md#beware-of-the-nomenclature

This CL was uploaded by git cl split.

R=horo@chromium.org

Bug: 925652
Change-Id: I4b558b880e6c19e396bb257d3ac6cbab335968f8
Reviewed-on: https://chromium-review.googlesource.com/c/1437347
Commit-Queue: Matt Falkenhagen <falken@chromium.org>
Reviewed-by: default avatarTsuyoshi Horo <horo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#626421}
parent f2110ca4
...@@ -980,8 +980,8 @@ TEST_P(EmbeddedWorkerInstanceTest, AbruptCompletion) { ...@@ -980,8 +980,8 @@ TEST_P(EmbeddedWorkerInstanceTest, AbruptCompletion) {
worker->Stop(); worker->Stop();
} }
INSTANTIATE_TEST_CASE_P(IsServiceWorkerServicificationEnabled, INSTANTIATE_TEST_SUITE_P(IsServiceWorkerServicificationEnabled,
EmbeddedWorkerInstanceTest, EmbeddedWorkerInstanceTest,
::testing::Bool();); ::testing::Bool(););
} // namespace content } // namespace content
...@@ -990,8 +990,8 @@ TEST_P(ServiceWorkerContextRecoveryTest, DeleteAndStartOver) { ...@@ -990,8 +990,8 @@ TEST_P(ServiceWorkerContextRecoveryTest, DeleteAndStartOver) {
EXPECT_EQ(registration_id, notifications_[4].registration_id); EXPECT_EQ(registration_id, notifications_[4].registration_id);
} }
INSTANTIATE_TEST_CASE_P(ServiceWorkerContextRecoveryTest, INSTANTIATE_TEST_SUITE_P(ServiceWorkerContextRecoveryTest,
ServiceWorkerContextRecoveryTest, ServiceWorkerContextRecoveryTest,
testing::Bool() /* is_storage_on_disk */); testing::Bool() /* is_storage_on_disk */);
} // namespace content } // namespace content
...@@ -517,9 +517,9 @@ TEST_P(ServiceWorkerControlleeRequestHandlerTest, FallbackWithNoOfflineHeader) { ...@@ -517,9 +517,9 @@ TEST_P(ServiceWorkerControlleeRequestHandlerTest, FallbackWithNoOfflineHeader) {
} }
#endif // BUILDFLAG(ENABLE_OFFLINE_PAGE) #endif // BUILDFLAG(ENABLE_OFFLINE_PAGE)
INSTANTIATE_TEST_CASE_P(IsServiceWorkerServicificationEnabled, INSTANTIATE_TEST_SUITE_P(IsServiceWorkerServicificationEnabled,
ServiceWorkerControlleeRequestHandlerTest, ServiceWorkerControlleeRequestHandlerTest,
::testing::Bool();); ::testing::Bool(););
} // namespace service_worker_controllee_request_handler_unittest } // namespace service_worker_controllee_request_handler_unittest
} // namespace content } // namespace content
...@@ -414,8 +414,8 @@ TEST_P(ServiceWorkerDataPipeReaderTestP, AsyncAbort) { ...@@ -414,8 +414,8 @@ TEST_P(ServiceWorkerDataPipeReaderTestP, AsyncAbort) {
mock_url_request_job()->results()[0]); mock_url_request_job()->results()[0]);
} }
INSTANTIATE_TEST_CASE_P(ServiceWorkerDataPipeReaderTest, INSTANTIATE_TEST_SUITE_P(ServiceWorkerDataPipeReaderTest,
ServiceWorkerDataPipeReaderTestP, ServiceWorkerDataPipeReaderTestP,
testing::Combine(testing::Bool(), testing::Bool())); testing::Combine(testing::Bool(), testing::Bool()));
} // namespace content } // namespace content
...@@ -319,9 +319,10 @@ IN_PROC_BROWSER_TEST_P(ServiceWorkerFileUploadTest, ...@@ -319,9 +319,10 @@ IN_PROC_BROWSER_TEST_P(ServiceWorkerFileUploadTest,
RunNetworkFallbackTest(TargetOrigin::kCrossOrigin); RunNetworkFallbackTest(TargetOrigin::kCrossOrigin);
} }
INSTANTIATE_TEST_CASE_P(/* no prefix */, INSTANTIATE_TEST_SUITE_P(
ServiceWorkerFileUploadTest, /* no prefix */,
::testing::Values(ServicifiedFeatures::kNone, ServiceWorkerFileUploadTest,
ServicifiedFeatures::kServiceWorker)); ::testing::Values(ServicifiedFeatures::kNone,
ServicifiedFeatures::kServiceWorker));
} // namespace content } // namespace content
...@@ -1101,8 +1101,8 @@ TEST_P(ServiceWorkerProviderHostTest, HintToUpdateServiceWorkerMultiple) { ...@@ -1101,8 +1101,8 @@ TEST_P(ServiceWorkerProviderHostTest, HintToUpdateServiceWorkerMultiple) {
ExpectUpdateIsScheduled(version3.get()); ExpectUpdateIsScheduled(version3.get());
} }
INSTANTIATE_TEST_CASE_P(IsServiceWorkerServicificationEnabled, INSTANTIATE_TEST_SUITE_P(IsServiceWorkerServicificationEnabled,
ServiceWorkerProviderHostTest, ServiceWorkerProviderHostTest,
::testing::Bool();); ::testing::Bool(););
} // namespace content } // namespace content
...@@ -763,9 +763,9 @@ TEST_P(ServiceWorkerActivationTest, LameDuckTime_NoControllee) { ...@@ -763,9 +763,9 @@ TEST_P(ServiceWorkerActivationTest, LameDuckTime_NoControllee) {
EXPECT_FALSE(IsLameDuckTimerRunning()); EXPECT_FALSE(IsLameDuckTimerRunning());
} }
INSTANTIATE_TEST_CASE_P(ServiceWorkerActivationTestWithDevTools, INSTANTIATE_TEST_SUITE_P(ServiceWorkerActivationTestWithDevTools,
ServiceWorkerActivationTest, ServiceWorkerActivationTest,
testing::Bool()); testing::Bool());
// Sets up a registration with a ServiceWorkerRegistrationObjectHost to hold it. // Sets up a registration with a ServiceWorkerRegistrationObjectHost to hold it.
class ServiceWorkerRegistrationObjectHostTest class ServiceWorkerRegistrationObjectHostTest
......
...@@ -137,10 +137,10 @@ IN_PROC_BROWSER_TEST_P(ServiceWorkerTlsTest, ClientAuthFetchSubResource) { ...@@ -137,10 +137,10 @@ IN_PROC_BROWSER_TEST_P(ServiceWorkerTlsTest, ClientAuthFetchSubResource) {
EXPECT_EQ(1, select_certificate_count()); EXPECT_EQ(1, select_certificate_count());
} }
INSTANTIATE_TEST_CASE_P(/* no prefix */, INSTANTIATE_TEST_SUITE_P(/* no prefix */,
ServiceWorkerTlsTest, ServiceWorkerTlsTest,
::testing::Values(ServicifiedFeatures::kNone, ::testing::Values(ServicifiedFeatures::kNone,
ServicifiedFeatures::kServiceWorker, ServicifiedFeatures::kServiceWorker,
ServicifiedFeatures::kNetwork)); ServicifiedFeatures::kNetwork));
} // namespace content } // namespace content
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment