Commit 80520100 authored by John Z Wu's avatar John Z Wu Committed by Commit Bot

Rename WebViewTest to WebViewIntTest.

Bug: 
Cq-Include-Trybots: master.tryserver.chromium.mac:ios-simulator-cronet;master.tryserver.chromium.mac:ios-simulator-full-configs
Change-Id: I0325f555d2dc6c0fd4fa2e746844095e65c001c6
Reviewed-on: https://chromium-review.googlesource.com/767072Reviewed-by: default avatarEugene But <eugenebut@chromium.org>
Commit-Queue: John Wu <jzw@chromium.org>
Cr-Commit-Position: refs/heads/master@{#516141}
parent 1c81957e
......@@ -16,10 +16,10 @@ group("all_tests") {
test("ios_web_view_inttests") {
testonly = true
sources = [
"web_view_int_test.h",
"web_view_int_test.mm",
"web_view_kvo_inttest.mm",
"web_view_restorable_state_inttest.mm",
"web_view_test.h",
"web_view_test.mm",
]
deps = [
......
......@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef IOS_WEB_VIEW_TEST_WEB_VIEW_TEST_H_
#define IOS_WEB_VIEW_TEST_WEB_VIEW_TEST_H_
#ifndef IOS_WEB_VIEW_TEST_WEB_VIEW_INT_TEST_H_
#define IOS_WEB_VIEW_TEST_WEB_VIEW_INT_TEST_H_
#include <memory>
#include <string>
......@@ -26,10 +26,10 @@ namespace ios_web_view {
// A test fixture for testing CWVWebView. A test server is also created to
// support loading content. The server supports the urls returned by the GetUrl*
// methods below.
class WebViewTest : public PlatformTest {
class WebViewIntTest : public PlatformTest {
protected:
WebViewTest();
~WebViewTest() override;
WebViewIntTest();
~WebViewIntTest() override;
// Returns URL to an html page with title set to |title|.
GURL GetUrlForPageWithTitle(const std::string& title);
......@@ -56,4 +56,4 @@ class WebViewTest : public PlatformTest {
} // namespace ios_web_view
#endif // IOS_WEB_VIEW_TEST_WEB_VIEW_TEST_H_
#endif // IOS_WEB_VIEW_TEST_WEB_VIEW_INT_TEST_H_
......@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#import "ios/web_view/test/web_view_test.h"
#import "ios/web_view/test/web_view_int_test.h"
#import <ChromeWebView/ChromeWebView.h>
#import <Foundation/Foundation.h>
......@@ -96,30 +96,30 @@ std::unique_ptr<net::test_server::HttpResponse> TestRequestHandler(
namespace ios_web_view {
WebViewTest::WebViewTest()
WebViewIntTest::WebViewIntTest()
: web_view_(test::CreateWebView()),
test_server_(base::MakeUnique<net::EmbeddedTestServer>(
net::test_server::EmbeddedTestServer::TYPE_HTTP)) {
test_server_->RegisterRequestHandler(base::Bind(&TestRequestHandler));
}
WebViewTest::~WebViewTest() = default;
WebViewIntTest::~WebViewIntTest() = default;
void WebViewTest::SetUp() {
void WebViewIntTest::SetUp() {
PlatformTest::SetUp();
ASSERT_TRUE(test_server_->Start());
}
GURL WebViewTest::GetUrlForPageWithTitle(const std::string& title) {
GURL WebViewIntTest::GetUrlForPageWithTitle(const std::string& title) {
return GetUrlForPageWithTitleAndBody(title, std::string());
}
GURL WebViewTest::GetUrlForPageWithHtmlBody(const std::string& html) {
GURL WebViewIntTest::GetUrlForPageWithHtmlBody(const std::string& html) {
return GetUrlForPageWithTitleAndBody(std::string(), html);
}
GURL WebViewTest::GetUrlForPageWithTitleAndBody(const std::string& title,
const std::string& body) {
GURL WebViewIntTest::GetUrlForPageWithTitleAndBody(const std::string& title,
const std::string& body) {
GURL url = test_server_->GetURL(kPageHtmlPath);
// Encode |title| and |body| in url query in order to build the server
......
......@@ -9,7 +9,7 @@
#import "base/strings/sys_string_conversions.h"
#import "ios/testing/wait_util.h"
#import "ios/web_view/test/observer.h"
#import "ios/web_view/test/web_view_test.h"
#import "ios/web_view/test/web_view_int_test.h"
#import "ios/web_view/test/web_view_test_util.h"
#import "net/base/mac/url_conversions.h"
#include "testing/gtest_mac.h"
......@@ -23,7 +23,7 @@ namespace ios_web_view {
// Tests that the KVO compliant properties of CWVWebView correctly report
// changes.
typedef ios_web_view::WebViewTest WebViewKvoTest;
typedef ios_web_view::WebViewIntTest WebViewKvoTest;
// Tests that CWVWebView correctly reports |canGoBack| and |canGoForward| state.
TEST_F(WebViewKvoTest, CanGoBackForward) {
......
......@@ -4,7 +4,7 @@
#import <ChromeWebView/ChromeWebView.h>
#import "ios/web_view/test/web_view_test.h"
#import "ios/web_view/test/web_view_int_test.h"
#import "ios/web_view/test/web_view_test_util.h"
#include "testing/gtest_mac.h"
......@@ -34,7 +34,7 @@ CWVWebView* CreateWebViewWithState(CWVWebView* source_web_view) {
// Tests encodeRestorableStateWithCoder: and decodeRestorableStateWithCoder:
// methods.
typedef ios_web_view::WebViewTest WebViewRestorableStateTest;
typedef ios_web_view::WebViewIntTest WebViewRestorableStateTest;
TEST_F(WebViewRestorableStateTest, EncodeDecode) {
// Load 2 URLs to create non-default state.
ASSERT_FALSE([web_view_ lastCommittedURL]);
......
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