Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 "base/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/callback.h" | 6 #include "base/callback.h" |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/run_loop.h" | 8 #include "base/run_loop.h" |
| 9 #include "content/browser/fileapi/chrome_blob_storage_context.h" | 9 #include "content/browser/fileapi/chrome_blob_storage_context.h" |
| 10 #include "content/browser/service_worker/embedded_worker_instance.h" | 10 #include "content/browser/service_worker/embedded_worker_instance.h" |
| (...skipping 21 matching lines...) Expand all Loading... | |
| 32 #include "webkit/common/blob/blob_data.h" | 32 #include "webkit/common/blob/blob_data.h" |
| 33 | 33 |
| 34 namespace content { | 34 namespace content { |
| 35 | 35 |
| 36 namespace { | 36 namespace { |
| 37 | 37 |
| 38 struct FetchResult { | 38 struct FetchResult { |
| 39 ServiceWorkerStatusCode status; | 39 ServiceWorkerStatusCode status; |
| 40 ServiceWorkerFetchEventResult result; | 40 ServiceWorkerFetchEventResult result; |
| 41 ServiceWorkerResponse response; | 41 ServiceWorkerResponse response; |
| 42 scoped_ptr<webkit_blob::BlobDataHandle> blob_data_handle; | |
| 42 }; | 43 }; |
| 43 | 44 |
| 44 void RunAndQuit(const base::Closure& closure, | 45 void RunAndQuit(const base::Closure& closure, |
| 45 const base::Closure& quit, | 46 const base::Closure& quit, |
| 46 base::MessageLoopProxy* original_message_loop) { | 47 base::MessageLoopProxy* original_message_loop) { |
| 47 closure.Run(); | 48 closure.Run(); |
| 48 original_message_loop->PostTask(FROM_HERE, quit); | 49 original_message_loop->PostTask(FROM_HERE, quit); |
| 49 } | 50 } |
| 50 | 51 |
| 51 void RunOnIOThread(const base::Closure& closure) { | 52 void RunOnIOThread(const base::Closure& closure) { |
| (...skipping 17 matching lines...) Expand all Loading... | |
| 69 FROM_HERE, | 70 FROM_HERE, |
| 70 base::Bind(closure, quit_on_original_thread)); | 71 base::Bind(closure, quit_on_original_thread)); |
| 71 run_loop.Run(); | 72 run_loop.Run(); |
| 72 } | 73 } |
| 73 | 74 |
| 74 // Contrary to the style guide, the output parameter of this function comes | 75 // Contrary to the style guide, the output parameter of this function comes |
| 75 // before input parameters so Bind can be used on it to create a FetchCallback | 76 // before input parameters so Bind can be used on it to create a FetchCallback |
| 76 // to pass to DispatchFetchEvent. | 77 // to pass to DispatchFetchEvent. |
| 77 void ReceiveFetchResult(BrowserThread::ID run_quit_thread, | 78 void ReceiveFetchResult(BrowserThread::ID run_quit_thread, |
| 78 const base::Closure& quit, | 79 const base::Closure& quit, |
| 80 ChromeBlobStorageContext* blob_context, | |
| 79 FetchResult* out_result, | 81 FetchResult* out_result, |
| 80 ServiceWorkerStatusCode actual_status, | 82 ServiceWorkerStatusCode actual_status, |
| 81 ServiceWorkerFetchEventResult actual_result, | 83 ServiceWorkerFetchEventResult actual_result, |
| 82 const ServiceWorkerResponse& actual_response) { | 84 const ServiceWorkerResponse& actual_response) { |
| 83 out_result->status = actual_status; | 85 out_result->status = actual_status; |
| 84 out_result->result = actual_result; | 86 out_result->result = actual_result; |
| 85 out_result->response = actual_response; | 87 out_result->response = actual_response; |
| 88 if (!actual_response.blob_uuid.empty()) { | |
| 89 out_result->blob_data_handle = | |
| 90 blob_context->context()->GetBlobDataFromUUID( | |
| 91 actual_response.blob_uuid); | |
| 92 } | |
| 86 if (!quit.is_null()) | 93 if (!quit.is_null()) |
| 87 BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, quit); | 94 BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, quit); |
| 88 } | 95 } |
| 89 | 96 |
| 90 ServiceWorkerVersion::FetchCallback CreateResponseReceiver( | 97 ServiceWorkerVersion::FetchCallback CreateResponseReceiver( |
| 91 BrowserThread::ID run_quit_thread, | 98 BrowserThread::ID run_quit_thread, |
| 92 const base::Closure& quit, | 99 const base::Closure& quit, |
| 100 ChromeBlobStorageContext* blob_context, | |
| 93 FetchResult* result) { | 101 FetchResult* result) { |
| 94 return base::Bind(&ReceiveFetchResult, run_quit_thread, quit, result); | 102 return base::Bind(&ReceiveFetchResult, run_quit_thread, quit, |
| 103 blob_context, result); | |
| 95 } | 104 } |
| 96 | 105 |
| 97 void ReadResponseBody(std::string* body, | 106 void ReadResponseBody(std::string* body, |
| 98 scoped_refptr<ChromeBlobStorageContext> context, | 107 webkit_blob::BlobDataHandle* blob_data_handle) { |
|
falken
2014/06/06 23:55:50
Would it be useful to add ASSERT_TRUE(blob_data_ha
michaeln
2014/06/07 00:00:02
Done
| |
| 99 std::string blob_uuid) { | |
| 100 scoped_ptr<webkit_blob::BlobDataHandle> blob_data_handle = | |
| 101 context->context()->GetBlobDataFromUUID(blob_uuid); | |
| 102 ASSERT_EQ(1U, blob_data_handle->data()->items().size()); | 108 ASSERT_EQ(1U, blob_data_handle->data()->items().size()); |
| 103 *body = std::string(blob_data_handle->data()->items()[0].bytes(), | 109 *body = std::string(blob_data_handle->data()->items()[0].bytes(), |
| 104 blob_data_handle->data()->items()[0].length()); | 110 blob_data_handle->data()->items()[0].length()); |
| 105 } | 111 } |
| 106 | 112 |
| 107 } // namespace | 113 } // namespace |
| 108 | 114 |
| 109 class ServiceWorkerBrowserTest : public ContentBrowserTest { | 115 class ServiceWorkerBrowserTest : public ContentBrowserTest { |
| 110 protected: | 116 protected: |
| 111 typedef ServiceWorkerBrowserTest self; | 117 typedef ServiceWorkerBrowserTest self; |
| (...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 293 base::RunLoop run_loop; | 299 base::RunLoop run_loop; |
| 294 BrowserThread::PostTask( | 300 BrowserThread::PostTask( |
| 295 BrowserThread::IO, | 301 BrowserThread::IO, |
| 296 FROM_HERE, | 302 FROM_HERE, |
| 297 base::Bind( | 303 base::Bind( |
| 298 &self::ActivateOnIOThread, this, run_loop.QuitClosure(), &status)); | 304 &self::ActivateOnIOThread, this, run_loop.QuitClosure(), &status)); |
| 299 run_loop.Run(); | 305 run_loop.Run(); |
| 300 ASSERT_EQ(expected_status, status); | 306 ASSERT_EQ(expected_status, status); |
| 301 } | 307 } |
| 302 | 308 |
| 303 void FetchOnRegisteredWorker(ServiceWorkerFetchEventResult* result, | 309 void FetchOnRegisteredWorker( |
| 304 ServiceWorkerResponse* response) { | 310 ServiceWorkerFetchEventResult* result, |
| 311 ServiceWorkerResponse* response, | |
| 312 scoped_ptr<webkit_blob::BlobDataHandle>* blob_data_handle) { | |
| 313 blob_context_ = ChromeBlobStorageContext::GetFor( | |
| 314 shell()->web_contents()->GetBrowserContext()); | |
| 305 FetchResult fetch_result; | 315 FetchResult fetch_result; |
| 306 fetch_result.status = SERVICE_WORKER_ERROR_FAILED; | 316 fetch_result.status = SERVICE_WORKER_ERROR_FAILED; |
| 307 base::RunLoop fetch_run_loop; | 317 base::RunLoop fetch_run_loop; |
| 308 BrowserThread::PostTask(BrowserThread::IO, | 318 BrowserThread::PostTask(BrowserThread::IO, |
| 309 FROM_HERE, | 319 FROM_HERE, |
| 310 base::Bind(&self::FetchOnIOThread, | 320 base::Bind(&self::FetchOnIOThread, |
| 311 this, | 321 this, |
| 312 fetch_run_loop.QuitClosure(), | 322 fetch_run_loop.QuitClosure(), |
| 313 &fetch_result)); | 323 &fetch_result)); |
| 314 fetch_run_loop.Run(); | 324 fetch_run_loop.Run(); |
| 315 *result = fetch_result.result; | 325 *result = fetch_result.result; |
| 316 *response = fetch_result.response; | 326 *response = fetch_result.response; |
| 327 *blob_data_handle = fetch_result.blob_data_handle.Pass(); | |
| 317 ASSERT_EQ(SERVICE_WORKER_OK, fetch_result.status); | 328 ASSERT_EQ(SERVICE_WORKER_OK, fetch_result.status); |
| 318 } | 329 } |
| 319 | 330 |
| 320 void FetchTestHelper(const std::string& worker_url, | 331 void FetchTestHelper( |
| 321 ServiceWorkerFetchEventResult* result, | 332 const std::string& worker_url, |
| 322 ServiceWorkerResponse* response) { | 333 ServiceWorkerFetchEventResult* result, |
| 334 ServiceWorkerResponse* response, | |
| 335 scoped_ptr<webkit_blob::BlobDataHandle>* blob_data_handle) { | |
| 323 RunOnIOThread( | 336 RunOnIOThread( |
| 324 base::Bind(&self::SetUpRegistrationOnIOThread, this, worker_url)); | 337 base::Bind(&self::SetUpRegistrationOnIOThread, this, worker_url)); |
| 325 | 338 FetchOnRegisteredWorker(result, response, blob_data_handle); |
| 326 FetchOnRegisteredWorker(result, response); | |
| 327 } | 339 } |
| 328 | 340 |
| 329 void SetUpRegistrationOnIOThread(const std::string& worker_url) { | 341 void SetUpRegistrationOnIOThread(const std::string& worker_url) { |
| 330 registration_ = new ServiceWorkerRegistration( | 342 registration_ = new ServiceWorkerRegistration( |
| 331 embedded_test_server()->GetURL("/*"), | 343 embedded_test_server()->GetURL("/*"), |
| 332 embedded_test_server()->GetURL(worker_url), | 344 embedded_test_server()->GetURL(worker_url), |
| 333 wrapper()->context()->storage()->NewRegistrationId(), | 345 wrapper()->context()->storage()->NewRegistrationId(), |
| 334 wrapper()->context()->AsWeakPtr()); | 346 wrapper()->context()->AsWeakPtr()); |
| 335 version_ = new ServiceWorkerVersion( | 347 version_ = new ServiceWorkerVersion( |
| 336 registration_, | 348 registration_, |
| (...skipping 24 matching lines...) Expand all Loading... | |
| 361 } | 373 } |
| 362 | 374 |
| 363 void FetchOnIOThread(const base::Closure& done, FetchResult* result) { | 375 void FetchOnIOThread(const base::Closure& done, FetchResult* result) { |
| 364 ASSERT_TRUE(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 376 ASSERT_TRUE(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 365 ServiceWorkerFetchRequest request( | 377 ServiceWorkerFetchRequest request( |
| 366 embedded_test_server()->GetURL("/service_worker/empty.html"), | 378 embedded_test_server()->GetURL("/service_worker/empty.html"), |
| 367 "GET", | 379 "GET", |
| 368 std::map<std::string, std::string>()); | 380 std::map<std::string, std::string>()); |
| 369 version_->SetStatus(ServiceWorkerVersion::ACTIVE); | 381 version_->SetStatus(ServiceWorkerVersion::ACTIVE); |
| 370 version_->DispatchFetchEvent( | 382 version_->DispatchFetchEvent( |
| 371 request, CreateResponseReceiver(BrowserThread::UI, done, result)); | 383 request, CreateResponseReceiver(BrowserThread::UI, done, |
| 384 blob_context_, result)); | |
| 372 } | 385 } |
| 373 | 386 |
| 374 void StopOnIOThread(const base::Closure& done, | 387 void StopOnIOThread(const base::Closure& done, |
| 375 ServiceWorkerStatusCode* result) { | 388 ServiceWorkerStatusCode* result) { |
| 376 ASSERT_TRUE(version_); | 389 ASSERT_TRUE(version_); |
| 377 version_->StopWorker(CreateReceiver(BrowserThread::UI, done, result)); | 390 version_->StopWorker(CreateReceiver(BrowserThread::UI, done, result)); |
| 378 } | 391 } |
| 379 | 392 |
| 380 void SyncEventOnIOThread(const base::Closure& done, | 393 void SyncEventOnIOThread(const base::Closure& done, |
| 381 ServiceWorkerStatusCode* result) { | 394 ServiceWorkerStatusCode* result) { |
| 382 ASSERT_TRUE(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 395 ASSERT_TRUE(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 383 version_->SetStatus(ServiceWorkerVersion::ACTIVE); | 396 version_->SetStatus(ServiceWorkerVersion::ACTIVE); |
| 384 version_->DispatchSyncEvent( | 397 version_->DispatchSyncEvent( |
| 385 CreateReceiver(BrowserThread::UI, done, result)); | 398 CreateReceiver(BrowserThread::UI, done, result)); |
| 386 } | 399 } |
| 387 | 400 |
| 388 protected: | 401 protected: |
| 389 scoped_refptr<ServiceWorkerRegistration> registration_; | 402 scoped_refptr<ServiceWorkerRegistration> registration_; |
| 390 scoped_refptr<ServiceWorkerVersion> version_; | 403 scoped_refptr<ServiceWorkerVersion> version_; |
| 404 scoped_refptr<ChromeBlobStorageContext> blob_context_; | |
| 391 }; | 405 }; |
| 392 | 406 |
| 393 IN_PROC_BROWSER_TEST_F(EmbeddedWorkerBrowserTest, StartAndStop) { | 407 IN_PROC_BROWSER_TEST_F(EmbeddedWorkerBrowserTest, StartAndStop) { |
| 394 // Start a worker and wait until OnStarted() is called. | 408 // Start a worker and wait until OnStarted() is called. |
| 395 base::RunLoop start_run_loop; | 409 base::RunLoop start_run_loop; |
| 396 done_closure_ = start_run_loop.QuitClosure(); | 410 done_closure_ = start_run_loop.QuitClosure(); |
| 397 BrowserThread::PostTask(BrowserThread::IO, FROM_HERE, | 411 BrowserThread::PostTask(BrowserThread::IO, FROM_HERE, |
| 398 base::Bind(&self::StartOnIOThread, this)); | 412 base::Bind(&self::StartOnIOThread, this)); |
| 399 start_run_loop.Run(); | 413 start_run_loop.Run(); |
| 400 | 414 |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 473 | 487 |
| 474 IN_PROC_BROWSER_TEST_F(ServiceWorkerVersionBrowserTest, | 488 IN_PROC_BROWSER_TEST_F(ServiceWorkerVersionBrowserTest, |
| 475 InstallWithWaitUntil_Rejected) { | 489 InstallWithWaitUntil_Rejected) { |
| 476 InstallTestHelper("/service_worker/worker_install_rejected.js", | 490 InstallTestHelper("/service_worker/worker_install_rejected.js", |
| 477 SERVICE_WORKER_ERROR_INSTALL_WORKER_FAILED); | 491 SERVICE_WORKER_ERROR_INSTALL_WORKER_FAILED); |
| 478 } | 492 } |
| 479 | 493 |
| 480 IN_PROC_BROWSER_TEST_F(ServiceWorkerVersionBrowserTest, FetchEvent_Response) { | 494 IN_PROC_BROWSER_TEST_F(ServiceWorkerVersionBrowserTest, FetchEvent_Response) { |
| 481 ServiceWorkerFetchEventResult result; | 495 ServiceWorkerFetchEventResult result; |
| 482 ServiceWorkerResponse response; | 496 ServiceWorkerResponse response; |
| 483 FetchTestHelper("/service_worker/fetch_event.js", &result, &response); | 497 scoped_ptr<webkit_blob::BlobDataHandle> blob_data_handle; |
| 498 FetchTestHelper("/service_worker/fetch_event.js", | |
| 499 &result, &response, &blob_data_handle); | |
| 484 ASSERT_EQ(SERVICE_WORKER_FETCH_EVENT_RESULT_RESPONSE, result); | 500 ASSERT_EQ(SERVICE_WORKER_FETCH_EVENT_RESULT_RESPONSE, result); |
| 485 EXPECT_EQ(301, response.status_code); | 501 EXPECT_EQ(301, response.status_code); |
| 486 EXPECT_EQ("Moved Permanently", response.status_text); | 502 EXPECT_EQ("Moved Permanently", response.status_text); |
| 487 std::map<std::string, std::string> expected_headers; | 503 std::map<std::string, std::string> expected_headers; |
| 488 expected_headers["Content-Language"] = "fi"; | 504 expected_headers["Content-Language"] = "fi"; |
| 489 expected_headers["Content-Type"] = "text/html; charset=UTF-8"; | 505 expected_headers["Content-Type"] = "text/html; charset=UTF-8"; |
| 490 EXPECT_EQ(expected_headers, response.headers); | 506 EXPECT_EQ(expected_headers, response.headers); |
| 491 | 507 |
| 492 scoped_refptr<ChromeBlobStorageContext> context = | |
| 493 ChromeBlobStorageContext::GetFor( | |
| 494 shell()->web_contents()->GetBrowserContext()); | |
| 495 std::string body; | 508 std::string body; |
| 496 RunOnIOThread( | 509 RunOnIOThread( |
| 497 base::Bind(&ReadResponseBody, &body, context, response.blob_uuid)); | 510 base::Bind(&ReadResponseBody, |
| 511 &body, base::Owned(blob_data_handle.release()))); | |
| 498 EXPECT_EQ("This resource is gone. Gone, gone, gone.", body); | 512 EXPECT_EQ("This resource is gone. Gone, gone, gone.", body); |
| 499 } | 513 } |
| 500 | 514 |
| 501 IN_PROC_BROWSER_TEST_F(ServiceWorkerVersionBrowserTest, | 515 IN_PROC_BROWSER_TEST_F(ServiceWorkerVersionBrowserTest, |
| 502 SyncAbortedWithoutFlag) { | 516 SyncAbortedWithoutFlag) { |
| 503 RunOnIOThread(base::Bind( | 517 RunOnIOThread(base::Bind( |
| 504 &self::SetUpRegistrationOnIOThread, this, "/service_worker/sync.js")); | 518 &self::SetUpRegistrationOnIOThread, this, "/service_worker/sync.js")); |
| 505 | 519 |
| 506 // Run the sync event. | 520 // Run the sync event. |
| 507 ServiceWorkerStatusCode status = SERVICE_WORKER_ERROR_FAILED; | 521 ServiceWorkerStatusCode status = SERVICE_WORKER_ERROR_FAILED; |
| 508 base::RunLoop sync_run_loop; | 522 base::RunLoop sync_run_loop; |
| 509 BrowserThread::PostTask(BrowserThread::IO, | 523 BrowserThread::PostTask(BrowserThread::IO, |
| 510 FROM_HERE, | 524 FROM_HERE, |
| 511 base::Bind(&self::SyncEventOnIOThread, | 525 base::Bind(&self::SyncEventOnIOThread, |
| 512 this, | 526 this, |
| 513 sync_run_loop.QuitClosure(), | 527 sync_run_loop.QuitClosure(), |
| 514 &status)); | 528 &status)); |
| 515 sync_run_loop.Run(); | 529 sync_run_loop.Run(); |
| 516 ASSERT_EQ(SERVICE_WORKER_ERROR_ABORT, status); | 530 ASSERT_EQ(SERVICE_WORKER_ERROR_ABORT, status); |
| 517 } | 531 } |
| 518 | 532 |
| 519 IN_PROC_BROWSER_TEST_F(ServiceWorkerVersionBrowserTest, SyncEventHandled) { | 533 IN_PROC_BROWSER_TEST_F(ServiceWorkerVersionBrowserTest, SyncEventHandled) { |
| 520 CommandLine* command_line = CommandLine::ForCurrentProcess(); | 534 CommandLine* command_line = CommandLine::ForCurrentProcess(); |
| 521 command_line->AppendSwitch(switches::kEnableServiceWorkerSync); | 535 command_line->AppendSwitch(switches::kEnableServiceWorkerSync); |
| 522 | 536 |
| 523 RunOnIOThread(base::Bind( | 537 RunOnIOThread(base::Bind( |
| 524 &self::SetUpRegistrationOnIOThread, this, "/service_worker/sync.js")); | 538 &self::SetUpRegistrationOnIOThread, this, "/service_worker/sync.js")); |
| 525 ServiceWorkerFetchEventResult result; | 539 ServiceWorkerFetchEventResult result; |
| 526 ServiceWorkerResponse response; | 540 ServiceWorkerResponse response; |
| 527 | 541 scoped_ptr<webkit_blob::BlobDataHandle> blob_data_handle; |
| 528 // Should 404 before sync event. | 542 // Should 404 before sync event. |
| 529 FetchOnRegisteredWorker(&result, &response); | 543 FetchOnRegisteredWorker(&result, &response, &blob_data_handle); |
| 530 EXPECT_EQ(404, response.status_code); | 544 EXPECT_EQ(404, response.status_code); |
| 531 | 545 |
| 532 // Run the sync event. | 546 // Run the sync event. |
| 533 ServiceWorkerStatusCode status = SERVICE_WORKER_ERROR_FAILED; | 547 ServiceWorkerStatusCode status = SERVICE_WORKER_ERROR_FAILED; |
| 534 base::RunLoop sync_run_loop; | 548 base::RunLoop sync_run_loop; |
| 535 BrowserThread::PostTask(BrowserThread::IO, | 549 BrowserThread::PostTask(BrowserThread::IO, |
| 536 FROM_HERE, | 550 FROM_HERE, |
| 537 base::Bind(&self::SyncEventOnIOThread, | 551 base::Bind(&self::SyncEventOnIOThread, |
| 538 this, | 552 this, |
| 539 sync_run_loop.QuitClosure(), | 553 sync_run_loop.QuitClosure(), |
| 540 &status)); | 554 &status)); |
| 541 sync_run_loop.Run(); | 555 sync_run_loop.Run(); |
| 542 ASSERT_EQ(SERVICE_WORKER_OK, status); | 556 ASSERT_EQ(SERVICE_WORKER_OK, status); |
| 543 | 557 |
| 544 // Should 200 after sync event. | 558 // Should 200 after sync event. |
| 545 FetchOnRegisteredWorker(&result, &response); | 559 FetchOnRegisteredWorker(&result, &response, &blob_data_handle); |
| 546 EXPECT_EQ(200, response.status_code); | 560 EXPECT_EQ(200, response.status_code); |
| 547 } | 561 } |
| 548 | 562 |
| 549 class ServiceWorkerBlackBoxBrowserTest : public ServiceWorkerBrowserTest { | 563 class ServiceWorkerBlackBoxBrowserTest : public ServiceWorkerBrowserTest { |
| 550 public: | 564 public: |
| 551 typedef ServiceWorkerBlackBoxBrowserTest self; | 565 typedef ServiceWorkerBlackBoxBrowserTest self; |
| 552 | 566 |
| 553 static void ExpectResultAndRun(bool expected, | 567 static void ExpectResultAndRun(bool expected, |
| 554 const base::Closure& continuation, | 568 const base::Closure& continuation, |
| 555 bool actual) { | 569 bool actual) { |
| (...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 679 base::Bind(&ServiceWorkerBlackBoxBrowserTest::FindRegistrationOnIO, | 693 base::Bind(&ServiceWorkerBlackBoxBrowserTest::FindRegistrationOnIO, |
| 680 this, | 694 this, |
| 681 embedded_test_server()->GetURL("/service_worker/empty.html"), | 695 embedded_test_server()->GetURL("/service_worker/empty.html"), |
| 682 &status, | 696 &status, |
| 683 &script_url)); | 697 &script_url)); |
| 684 EXPECT_EQ(SERVICE_WORKER_ERROR_NOT_FOUND, status); | 698 EXPECT_EQ(SERVICE_WORKER_ERROR_NOT_FOUND, status); |
| 685 } | 699 } |
| 686 } | 700 } |
| 687 | 701 |
| 688 } // namespace content | 702 } // namespace content |
| OLD | NEW |