Firefox-UI-Fix/__tests__/list.test.scss
2021-12-15 15:05:03 +09:00

31 lines
621 B
SCSS

@use 'true' as *;
@use "../src/utils/list";
// TODO: Need more tests..
$simpleList: (ab cd efgh ijk);
$dupList: (ab cd efgh efgh efgh ijk);
@include test-module("Remove at list [fn]") {
@include test("simple") {
@include assert-equal(
list.remove($simpleList, "cd"),
(ab efgh ijk)
);
}
@include test("duplicate") {
@include assert-equal(
list.remove($dupList, "efgh"),
(ab cd ijk)
);
}
}
@include test-module("Convert to str [fn]") {
@include test("simple") {
@include assert-equal(
list.to-string($simpleList),
(((null ab) cd) efgh) ijk
);
}
}