chromium/third_party/blink/renderer/core/dom/document_statistics_collector_test.cc

// Copyright 2015 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/dom/document_statistics_collector.h"

#include <memory>
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/public/platform/web_distillability.h"
#include "third_party/blink/renderer/core/dom/document.h"
#include "third_party/blink/renderer/core/frame/local_frame_view.h"
#include "third_party/blink/renderer/core/html/html_head_element.h"
#include "third_party/blink/renderer/core/html/html_link_element.h"
#include "third_party/blink/renderer/core/testing/page_test_base.h"
#include "third_party/blink/renderer/platform/heap/thread_state.h"
#include "third_party/blink/renderer/platform/wtf/text/string_builder.h"

namespace blink {

// Saturate the length of a paragraph to save time.
const unsigned kTextContentLengthSaturation =;

// Filter out short P elements. The threshold is set to around 2 English
// sentences.
const unsigned kParagraphLengthThreshold =;

class DocumentStatisticsCollectorTest : public PageTestBase {};

void DocumentStatisticsCollectorTest::SetHtmlInnerHTML(
    const String& html_content) {}

// This test checks open graph articles can be recognized.
TEST_F(DocumentStatisticsCollectorTest, HasOpenGraphArticle) {}

// This test checks non-existence of open graph articles can be recognized.
TEST_F(DocumentStatisticsCollectorTest, NoOpenGraphArticle) {}

// This test checks element counts are correct.
TEST_F(DocumentStatisticsCollectorTest, CountElements) {}

// This test checks score calculations are correct.
TEST_F(DocumentStatisticsCollectorTest, CountScore) {}

// This test checks saturation of score calculations is correct.
TEST_F(DocumentStatisticsCollectorTest, CountScoreSaturation) {}

}  // namespace blink