| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "ppapi/thunk/thunk.h" | 5 #include "ppapi/thunk/thunk.h" |
| 6 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" | 6 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" |
| 7 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrameClient.h" | 7 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrameClient.h" |
| 8 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLReques
t.h" | 8 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLReques
t.h" |
| 9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h" | 9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h" |
| 10 #include "webkit/glue/user_agent.h" | 10 #include "webkit/glue/user_agent.h" |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 static WebView* web_view_; | 116 static WebView* web_view_; |
| 117 static WebFrame* frame_; | 117 static WebFrame* frame_; |
| 118 }; | 118 }; |
| 119 | 119 |
| 120 TestWebFrameClient URLRequestInfoTest::web_frame_client_; | 120 TestWebFrameClient URLRequestInfoTest::web_frame_client_; |
| 121 WebView* URLRequestInfoTest::web_view_; | 121 WebView* URLRequestInfoTest::web_view_; |
| 122 WebFrame* URLRequestInfoTest::frame_; | 122 WebFrame* URLRequestInfoTest::frame_; |
| 123 | 123 |
| 124 TEST_F(URLRequestInfoTest, GetInterface) { | 124 TEST_F(URLRequestInfoTest, GetInterface) { |
| 125 const PPB_URLRequestInfo* request_info = | 125 const PPB_URLRequestInfo* request_info = |
| 126 ::ppapi::thunk::GetPPB_URLRequestInfo_Thunk(); | 126 ::ppapi::thunk::GetPPB_URLRequestInfo_1_0_Thunk(); |
| 127 EXPECT_TRUE(request_info); | 127 EXPECT_TRUE(request_info); |
| 128 EXPECT_TRUE(request_info->Create); | 128 EXPECT_TRUE(request_info->Create); |
| 129 EXPECT_TRUE(request_info->IsURLRequestInfo); | 129 EXPECT_TRUE(request_info->IsURLRequestInfo); |
| 130 EXPECT_TRUE(request_info->SetProperty); | 130 EXPECT_TRUE(request_info->SetProperty); |
| 131 EXPECT_TRUE(request_info->AppendDataToBody); | 131 EXPECT_TRUE(request_info->AppendDataToBody); |
| 132 EXPECT_TRUE(request_info->AppendFileToBody); | 132 EXPECT_TRUE(request_info->AppendFileToBody); |
| 133 } | 133 } |
| 134 | 134 |
| 135 TEST_F(URLRequestInfoTest, AsURLRequestInfo) { | 135 TEST_F(URLRequestInfoTest, AsURLRequestInfo) { |
| 136 EXPECT_EQ(info_, info_->AsPPB_URLRequestInfo_API()); | 136 EXPECT_EQ(info_, info_->AsPPB_URLRequestInfo_API()); |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 250 EXPECT_TRUE(IsExpected( | 250 EXPECT_TRUE(IsExpected( |
| 251 GetHeaderValue("foo"), "bar")); | 251 GetHeaderValue("foo"), "bar")); |
| 252 EXPECT_TRUE(IsExpected( | 252 EXPECT_TRUE(IsExpected( |
| 253 GetHeaderValue("bar"), "baz")); | 253 GetHeaderValue("bar"), "baz")); |
| 254 } | 254 } |
| 255 | 255 |
| 256 // TODO(bbudge) Unit tests for AppendDataToBody, AppendFileToBody. | 256 // TODO(bbudge) Unit tests for AppendDataToBody, AppendFileToBody. |
| 257 | 257 |
| 258 } // namespace ppapi | 258 } // namespace ppapi |
| 259 } // namespace webkit | 259 } // namespace webkit |
| 260 | |
| OLD | NEW |