| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "chrome/browser/chromeos/drive/search_metadata.h" | 5 #include "chrome/browser/chromeos/drive/search_metadata.h" |
| 6 | 6 |
| 7 #include "base/files/scoped_temp_dir.h" | 7 #include "base/files/scoped_temp_dir.h" |
| 8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
| 9 #include "base/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
| 10 #include "base/threading/sequenced_worker_pool.h" | 10 #include "base/threading/sequenced_worker_pool.h" |
| 11 #include "chrome/browser/chromeos/drive/fake_free_disk_space_getter.h" | 11 #include "chrome/browser/chromeos/drive/fake_free_disk_space_getter.h" |
| 12 #include "chrome/browser/chromeos/drive/file_cache.h" | 12 #include "chrome/browser/chromeos/drive/file_cache.h" |
| 13 #include "chrome/browser/chromeos/drive/file_system_util.h" | 13 #include "chrome/browser/chromeos/drive/file_system_util.h" |
| 14 #include "chrome/browser/chromeos/drive/test_util.h" | 14 #include "chrome/browser/chromeos/drive/test_util.h" |
| 15 #include "content/public/test/test_browser_thread.h" | 15 #include "content/public/test/test_browser_thread.h" |
| 16 #include "testing/gtest/include/gtest/gtest.h" | 16 #include "testing/gtest/include/gtest/gtest.h" |
| 17 | 17 |
| 18 namespace drive { | 18 namespace drive { |
| 19 namespace internal { | 19 namespace internal { |
| (...skipping 593 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 613 } | 613 } |
| 614 | 614 |
| 615 TEST(SearchMetadataSimpleTest, FindAndHighlight_MoreMetaChars) { | 615 TEST(SearchMetadataSimpleTest, FindAndHighlight_MoreMetaChars) { |
| 616 std::string highlighted_text; | 616 std::string highlighted_text; |
| 617 EXPECT_TRUE(FindAndHighlight("a&b&c&d", "b&c", &highlighted_text)); | 617 EXPECT_TRUE(FindAndHighlight("a&b&c&d", "b&c", &highlighted_text)); |
| 618 EXPECT_EQ("a&<b>b&c</b>&d", highlighted_text); | 618 EXPECT_EQ("a&<b>b&c</b>&d", highlighted_text); |
| 619 } | 619 } |
| 620 | 620 |
| 621 } // namespace internal | 621 } // namespace internal |
| 622 } // namespace drive | 622 } // namespace drive |
| OLD | NEW |