chromium/third_party/blink/renderer/core/fragment_directive/same_block_word_iterator_test.cc

// Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "third_party/blink/renderer/core/fragment_directive/same_block_word_iterator.h"

#include <gtest/gtest.h>

#include "third_party/blink/renderer/core/editing/position.h"
#include "third_party/blink/renderer/core/fragment_directive/same_block_word_iterator.h"
#include "third_party/blink/renderer/core/testing/sim/sim_request.h"
#include "third_party/blink/renderer/core/testing/sim/sim_test.h"
#include "third_party/blink/renderer/platform/heap/garbage_collected.h"

namespace blink {

class SameBlockWordIteratorTest : public SimTest {};

// Basic case for forward iterator->
TEST_F(SameBlockWordIteratorTest, GetNextWord) {}

// Check the case when following text contains collapsible space.
TEST_F(SameBlockWordIteratorTest, GetNextWord_ExtraSpace) {}

// Check the case when there is a commented block which should be skipped.
TEST_F(SameBlockWordIteratorTest, GetNextWord_WithComment) {}

// Check the case when following text contains non-block tag(e.g. <b>).
TEST_F(SameBlockWordIteratorTest, GetNextWord_NestedTextNode) {}

// Check the case when following text is interrupted by a nested block.
TEST_F(SameBlockWordIteratorTest, GetNextWord_NestedBlock) {}

// Check the case when following text includes non-block element but is
// interrupted by a nested block.
TEST_F(SameBlockWordIteratorTest, GetNextWord_NestedBlockInNestedText) {}

// Check the case when following text includes invisible block.
TEST_F(SameBlockWordIteratorTest, GetNextWord_NestedInvisibleBlock) {}

// Basic case for backward iterator->
TEST_F(SameBlockWordIteratorTest, GetPreviousWord) {}

// Check the case when available text has extra space.
TEST_F(SameBlockWordIteratorTest, GetPreviousWord_ExtraSpace) {}

// Check the case when there is a commented block which should be skipped.
TEST_F(SameBlockWordIteratorTest, GetPreviousWord_WithComment) {}

// Check the case when available text contains non-block tag(e.g. <b>).
TEST_F(SameBlockWordIteratorTest, GetPreviousWord_NestedTextNode) {}

// Check the case when available text is interrupted by a nested block.
TEST_F(SameBlockWordIteratorTest, GetPreviousWord_NestedBlock) {}

// Check the case when available text includes non-block element but is
// interrupted by a nested block.
TEST_F(SameBlockWordIteratorTest, GetPreviousWord_NestedBlockInNestedText) {}

// Check the case when available text includes invisible block.
TEST_F(SameBlockWordIteratorTest, GetPreviousWord_NestedInvisibleBlock) {}

// Check the case when given start position is in a middle of a word.
TEST_F(SameBlockWordIteratorTest, GetNextWord_HalfWord) {}

}  // namespace blink