#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "third_party/blink/renderer/core/css/css_test_helpers.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/renderer/bindings/core/v8/v8_css_style_sheet_init.h"
#include "third_party/blink/renderer/bindings/core/v8/v8_property_definition.h"
#include "third_party/blink/renderer/core/css/css_custom_ident_value.h"
#include "third_party/blink/renderer/core/css/css_numeric_literal_value.h"
#include "third_party/blink/renderer/core/css/css_rule_list.h"
#include "third_party/blink/renderer/core/css/css_style_sheet.h"
#include "third_party/blink/renderer/core/css/css_syntax_definition.h"
#include "third_party/blink/renderer/core/css/css_syntax_string_parser.h"
#include "third_party/blink/renderer/core/css/css_variable_data.h"
#include "third_party/blink/renderer/core/css/parser/css_parser.h"
#include "third_party/blink/renderer/core/css/parser/css_parser_context.h"
#include "third_party/blink/renderer/core/css/parser/css_parser_local_context.h"
#include "third_party/blink/renderer/core/css/parser/css_parser_token_stream.h"
#include "third_party/blink/renderer/core/css/parser/css_property_parser.h"
#include "third_party/blink/renderer/core/css/parser/css_selector_parser.h"
#include "third_party/blink/renderer/core/css/parser/css_tokenizer.h"
#include "third_party/blink/renderer/core/css/properties/css_property_ref.h"
#include "third_party/blink/renderer/core/css/properties/longhand.h"
#include "third_party/blink/renderer/core/css/property_registration.h"
#include "third_party/blink/renderer/core/css/property_registry.h"
#include "third_party/blink/renderer/core/css/rule_set.h"
#include "third_party/blink/renderer/core/css/style_engine.h"
#include "third_party/blink/renderer/core/css/style_sheet_contents.h"
#include "third_party/blink/renderer/core/dom/document.h"
#include "third_party/blink/renderer/core/execution_context/security_context.h"
#include "third_party/blink/renderer/core/testing/page_test_base.h"
#include "third_party/blink/renderer/platform/bindings/exception_state.h"
#include "third_party/blink/renderer/platform/heap/garbage_collected.h"
#include "third_party/blink/renderer/platform/wtf/text/text_encoding.h"
namespace blink {
namespace css_test_helpers {
TestStyleSheet::~TestStyleSheet() = default;
TestStyleSheet::TestStyleSheet() { … }
CSSRuleList* TestStyleSheet::CssRules() { … }
RuleSet& TestStyleSheet::GetRuleSet() { … }
void TestStyleSheet::AddCSSRules(const String& css_text, bool is_empty_sheet) { … }
CSSStyleSheet* CreateStyleSheet(Document& document) { … }
RuleSet* CreateRuleSet(Document& document, String text) { … }
PropertyRegistration* CreatePropertyRegistration(const String& name,
String syntax,
const CSSValue* initial_value,
bool is_inherited) { … }
PropertyRegistration* CreateLengthRegistration(const String& name, int px) { … }
void RegisterProperty(Document& document,
const String& name,
const String& syntax,
const std::optional<String>& initial_value,
bool is_inherited) { … }
void RegisterProperty(Document& document,
const String& name,
const String& syntax,
const std::optional<String>& initial_value,
bool is_inherited,
ExceptionState& exception_state) { … }
void DeclareProperty(Document& document,
const String& name,
const String& syntax,
const std::optional<String>& initial_value,
bool is_inherited) { … }
CSSVariableData* CreateVariableData(String s) { … }
const CSSValue* CreateCustomIdent(const char* s) { … }
const CSSValue* ParseLonghand(Document& document,
const CSSProperty& property,
const String& value) { … }
const CSSPropertyValueSet* ParseDeclarationBlock(const String& block_text,
CSSParserMode mode) { … }
StyleRuleBase* ParseRule(Document& document, String text) { … }
const CSSValue* ParseValue(Document& document, String syntax, String value) { … }
CSSSelectorList* ParseSelectorList(const String& string) { … }
CSSSelectorList* ParseSelectorList(const String& string,
CSSNestingType nesting_type,
const StyleRule* parent_rule_for_nesting,
bool is_within_scope) { … }
}
}