Skip to content

Commit

Permalink
Add more tests
Browse files Browse the repository at this point in the history
  • Loading branch information
kristerkari committed Dec 5, 2018
1 parent 0fa5584 commit 9127b1c
Showing 1 changed file with 37 additions and 2 deletions.
39 changes: 37 additions & 2 deletions src/rules/at-function-named-arguments/__tests__/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,18 @@ testRule(rule, {
) !default;
`,
description: "Always. Should ignore Sass maps with default."
},
{
code: `
$color: #123456;
$rgb: (
"r": red($red: $color),
"g": green($green: $color),
"b": blue($blue: $color)
);
`,
description: "Always. function call inside a map."
}
],

Expand Down Expand Up @@ -261,6 +273,18 @@ testRule(rule, {
column: 9,
description:
"Always. Example: native CSS function inside a function call."
},
{
code: `
$color: #123456;
$rgb: (
"r": red($color),
"g": green($color),
"b": blue($color)
);
`,
description: "Always. function call inside a map."
}
]
});
Expand Down Expand Up @@ -519,8 +543,19 @@ testRule(rule, {
line: 3,
column: 9,
message: messages.rejected,
description:
"Always. Example: native CSS function inside a function call."
description: "Never. Example: native CSS function inside a function call."
},
{
code: `
$color: #123456;
$rgb: (
"r": red($red: $color),
"g": green($green: $color),
"b": blue($green: $color)
);
`,
description: "Never. function call inside a map."
}
]
});
Expand Down

0 comments on commit 9127b1c

Please sign in to comment.