Commit 867d781c authored by Eugene But's avatar Eugene But Committed by Commit Bot

Use web::test::LoadUrl in DownloadTest.

Bug: None
Cq-Include-Trybots: master.tryserver.chromium.mac:ios-simulator-cronet;master.tryserver.chromium.mac:ios-simulator-full-configs
Change-Id: I61aa929e8ca773b15f54f05b5bcb44961d488c4a
Reviewed-on: https://chromium-review.googlesource.com/1052487Reviewed-by: default avatarKurt Horimoto <kkhorimoto@chromium.org>
Commit-Queue: Eugene But <eugenebut@chromium.org>
Cr-Commit-Position: refs/heads/master@{#557263}
parent adab4463
......@@ -9,8 +9,8 @@
#import "ios/testing/wait_util.h"
#import "ios/web/public/download/download_controller.h"
#import "ios/web/public/download/download_task.h"
#import "ios/web/public/navigation_manager.h"
#include "ios/web/public/test/fakes/fake_download_controller_delegate.h"
#import "ios/web/public/test/navigation_test_util.h"
#import "ios/web/public/test/web_test_with_web_state.h"
#import "ios/web/public/web_client.h"
#import "ios/web/public/web_state/web_state.h"
......@@ -74,9 +74,7 @@ TEST_F(DownloadTest, SucessfullDownload) {
// Load download URL.
ASSERT_TRUE(server_.Start());
GURL url(server_.GetURL("/"));
web::NavigationManager::WebLoadParams params(url);
params.transition_type = ui::PageTransition::PAGE_TRANSITION_TYPED;
web_state()->GetNavigationManager()->LoadURLWithParams(params);
test::LoadUrl(web_state(), url);
// Wait until download task is created.
ASSERT_TRUE(WaitUntilConditionOrTimeout(testing::kWaitForDownloadTimeout, ^{
......
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