OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/message_loop.h" | 5 #include "base/message_loop.h" |
6 #include "base/pickle.h" | 6 #include "base/pickle.h" |
7 #include "base/strings/utf_string_conversions.h" | 7 #include "base/strings/utf_string_conversions.h" |
8 #include "googleurl/src/gurl.h" | |
9 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
10 #include "testing/platform_test.h" | 9 #include "testing/platform_test.h" |
11 #include "ui/base/dragdrop/os_exchange_data.h" | 10 #include "ui/base/dragdrop/os_exchange_data.h" |
| 11 #include "url/gurl.h" |
12 | 12 |
13 namespace ui { | 13 namespace ui { |
14 | 14 |
15 class OSExchangeDataTest : public PlatformTest { | 15 class OSExchangeDataTest : public PlatformTest { |
16 private: | 16 private: |
17 base::MessageLoopForUI message_loop_; | 17 base::MessageLoopForUI message_loop_; |
18 }; | 18 }; |
19 | 19 |
20 TEST_F(OSExchangeDataTest, StringDataGetAndSet) { | 20 TEST_F(OSExchangeDataTest, StringDataGetAndSet) { |
21 OSExchangeData data; | 21 OSExchangeData data; |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 "</BODY>\n</HTML>"); | 89 "</BODY>\n</HTML>"); |
90 data.SetHtml(html, url); | 90 data.SetHtml(html, url); |
91 | 91 |
92 OSExchangeData copy(data.provider().Clone()); | 92 OSExchangeData copy(data.provider().Clone()); |
93 string16 read_html; | 93 string16 read_html; |
94 EXPECT_TRUE(copy.GetHtml(&read_html, &url)); | 94 EXPECT_TRUE(copy.GetHtml(&read_html, &url)); |
95 EXPECT_EQ(html, read_html); | 95 EXPECT_EQ(html, read_html); |
96 } | 96 } |
97 | 97 |
98 } // namespace ui | 98 } // namespace ui |
OLD | NEW |