chromium/components/subresource_filter/tools/rule_parser/rule_parser_unittest.cc

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

#ifdef UNSAFE_BUFFERS_BUILD
// TODO(crbug.com/40285824): Remove this and convert code to safer constructs.
#pragma allow_unsafe_buffers
#endif

#include "components/subresource_filter/tools/rule_parser/rule_parser.h"

#include <string>
#include <string_view>
#include <vector>

#include "components/subresource_filter/tools/rule_parser/rule.h"
#include "components/subresource_filter/tools/rule_parser/rule_options.h"
#include "components/url_pattern_index/proto/rules.pb.h"
#include "testing/gtest/include/gtest/gtest.h"

namespace subresource_filter {

namespace {

void ParseAndExpectUrlRule(std::string_view line,
                           const UrlRule& expected_rule) {}

void ParseAndExpectCssRule(std::string_view line,
                           const CssRule& expected_rule) {}

}  // namespace

TEST(RuleParserTest, ParseComment) {}

TEST(RuleParserTest, ParseUrlRule) {}

TEST(RuleParserTest, UrlRuleMatchCase) {}

TEST(RuleParserTest, ParseAllowlistUrlRule) {}

TEST(RuleParserTest, ParseEmptyOptions) {}

TEST(RuleParserTest, ParseSingleTypeOptions) {}

TEST(RuleParserTest, ParseSingleInverseTypeOptions) {}

TEST(RuleParserTest, ParseMultipleTypeOptions) {}

TEST(RuleParserTest, ParseContradictingTypeOptions) {}

TEST(RuleParserTest, ParseUrlRuleOptions) {}

TEST(RuleParserTest, ParseUrlRuleAnchors) {}

TEST(RuleParserTest, ParseUrlRuleWithBookmark) {}

TEST(RuleParserTest, ParseUrlRuleWithElementAndActivationTypes) {}

TEST(RuleParserTest, ParseUrlRuleWithRegexp) {}

TEST(RuleParserTest, ParseCssRules) {}

TEST(RuleParserTest, ParseErrors) {}

TEST(RuleParserTest, ParseNonEmptyUrlRuleWithEmptyUrlPattern) {}

}  // namespace subresource_filter