OLD | NEW |
(Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "core/editing/markers/SpellingMarker.h" |
| 6 |
| 7 #include "testing/gtest/include/gtest/gtest.h" |
| 8 |
| 9 namespace blink { |
| 10 |
| 11 const char* const kDescription = "Test description"; |
| 12 |
| 13 class SpellingMarkerTest : public ::testing::Test {}; |
| 14 |
| 15 TEST_F(SpellingMarkerTest, MarkerType) { |
| 16 DocumentMarker* marker = new SpellingMarker(0, 1, kDescription); |
| 17 EXPECT_EQ(DocumentMarker::kSpelling, marker->GetType()); |
| 18 } |
| 19 |
| 20 TEST_F(SpellingMarkerTest, IsSpellCheckMarker) { |
| 21 DocumentMarker* marker = new SpellingMarker(0, 1, kDescription); |
| 22 EXPECT_TRUE(IsSpellCheckMarker(*marker)); |
| 23 } |
| 24 |
| 25 TEST_F(SpellingMarkerTest, ConstructorAndGetters) { |
| 26 SpellingMarker* marker = new SpellingMarker(0, 1, kDescription); |
| 27 EXPECT_EQ(kDescription, marker->Description()); |
| 28 } |
| 29 |
| 30 } // namespace blink |
OLD | NEW |