global variables feature-exists

This commit is contained in:
ConnorSkees 2020-03-23 15:06:04 -04:00
parent 0f310e9582
commit 68d2bc7e17
2 changed files with 6 additions and 6 deletions

View File

@ -26,7 +26,7 @@ pub(crate) fn register(f: &mut HashMap<String, Builtin>) {
Value::Ident(s, _) => match s.as_str() {
// A local variable will shadow a global variable unless
// `!global` is used.
"global-variable-shadowing" => Ok(Value::False),
"global-variable-shadowing" => Ok(Value::True),
// the @extend rule will affect selectors nested in pseudo-classes
// like :not()
"extend-selector-pseudoclass" => Ok(Value::False),

View File

@ -44,11 +44,11 @@ test!(
"a {\n color: true;\n}\n"
);
// Uncomment as more features are added
// test!(
// feature_exists_global_variable_shadowing,
// "a {\n color: feature-exists(global-variable-shadowing)\n}\n",
// "a {\n color: true;\n}\n"
// );
test!(
feature_exists_global_variable_shadowing,
"a {\n color: feature-exists(global-variable-shadowing)\n}\n",
"a {\n color: true;\n}\n"
);
// test!(
// feature_exists_extend_selector_pseudoclass,
// "a {\n color: feature-exists(extend-selector-pseudoclass)\n}\n",