Skip to content

Commit

Permalink
Merge pull request #283 from mgreter/missing-tests
Browse files Browse the repository at this point in the history
Add missing tests and move some passing todos
  • Loading branch information
mgreter committed Mar 27, 2015
2 parents e3be7d7 + db1414b commit 971c244
Show file tree
Hide file tree
Showing 50 changed files with 128 additions and 0 deletions.
1 change: 1 addition & 0 deletions spec/libsass-closed-issues/issue_857/expected.compact.css
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#hello { color: red; }
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#hello{color:red}
3 changes: 3 additions & 0 deletions spec/libsass-closed-issues/issue_857/expected.expanded.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#hello {
color: red;
}
2 changes: 2 additions & 0 deletions spec/libsass-closed-issues/issue_857/expected_output.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#hello {
color: red; }
11 changes: 11 additions & 0 deletions spec/libsass-closed-issues/issue_857/input.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
$list: "item-1" "item-2" "item-3";

#hello {
@if length($list) % 2 == 0 {
color: blue;
}

@else {
color: red;
}
}
1 change: 1 addition & 0 deletions spec/libsass-closed-issues/issue_864/expected.compact.css
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
div { color: #999999; }
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
div{color:#999}
3 changes: 3 additions & 0 deletions spec/libsass-closed-issues/issue_864/expected.expanded.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
div {
color: #999999;
}
2 changes: 2 additions & 0 deletions spec/libsass-closed-issues/issue_864/expected_output.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
div {
color: #999999; }
1 change: 1 addition & 0 deletions spec/libsass-closed-issues/issue_864/input.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
div { color: desaturate(#999, 50%); }
1 change: 1 addition & 0 deletions spec/libsass-closed-issues/issue_893/expected.compact.css
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.row { margin: -20px; }
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.row{margin:-20px}
3 changes: 3 additions & 0 deletions spec/libsass-closed-issues/issue_893/expected.expanded.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.row {
margin: -20px;
}
2 changes: 2 additions & 0 deletions spec/libsass-closed-issues/issue_893/expected_output.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.row {
margin: -20px; }
5 changes: 5 additions & 0 deletions spec/libsass-closed-issues/issue_893/input.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
$gutter: 20px;

.row {
margin: 0 -$gutter;
}
3 changes: 3 additions & 0 deletions spec/libsass-closed-issues/issue_943/expected.compact.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@media (min-width: 10px) { .puppy:hover { display: none; } }

.puppy { background-color: red; }
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@media (min-width: 10px){.puppy:hover{display:none}}.puppy{background-color:red}
9 changes: 9 additions & 0 deletions spec/libsass-closed-issues/issue_943/expected.expanded.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
@media (min-width: 10px) {
.puppy:hover {
display: none;
}
}

.puppy {
background-color: red;
}
6 changes: 6 additions & 0 deletions spec/libsass-closed-issues/issue_943/expected_output.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
@media (min-width: 10px) {
.puppy:hover {
display: none; } }

.puppy {
background-color: red; }
12 changes: 12 additions & 0 deletions spec/libsass-closed-issues/issue_943/input.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
%dog {
@media (min-width: 10px) {
&:hover {
display: none;
}
}
}

.puppy {
@extend %dog;
background-color: red;
}
1 change: 1 addition & 0 deletions spec/libsass-closed-issues/issue_976/expected.compact.css
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@debug-this { .debug { foo: bar; } }
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@debug-this{.debug{foo:bar}}
5 changes: 5 additions & 0 deletions spec/libsass-closed-issues/issue_976/expected.expanded.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
@debug-this {
.debug {
foo: bar;
}
}
3 changes: 3 additions & 0 deletions spec/libsass-closed-issues/issue_976/expected_output.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@debug-this {
.debug {
foo: bar; } }
5 changes: 5 additions & 0 deletions spec/libsass-closed-issues/issue_976/input.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.debug {
@debug-this {
foo: bar;
}
}
1 change: 1 addition & 0 deletions spec/libsass-closed-issues/issue_980/expected.compact.css
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.test { value: 16; value: 7; value: 12; }
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.test{value:16;value:7;value:12}
5 changes: 5 additions & 0 deletions spec/libsass-closed-issues/issue_980/expected.expanded.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.test {
value: 16;
value: 7;
value: 12;
}
4 changes: 4 additions & 0 deletions spec/libsass-closed-issues/issue_980/expected_output.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
.test {
value: 16;
value: 7;
value: 12; }
13 changes: 13 additions & 0 deletions spec/libsass-closed-issues/issue_980/input.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
@function foo($value, $default: 13, $args...) {
$res: $value + $default;
@if length($args) != 0 {
$res: $res + nth($args, 1);
}
@return $res;
}

.test {
value: foo(3); // expected: 16
value: foo(3, 4); // expected: 7
value: foo(3, 4, 5, 6); // expected: 12
}
1 change: 1 addition & 0 deletions spec/libsass-closed-issues/issue_988/expected.compact.css
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.foo { content: "Foo-Bar-Baz-Qux"; }
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.foo{content:"Foo-Bar-Baz-Qux"}
3 changes: 3 additions & 0 deletions spec/libsass-closed-issues/issue_988/expected.expanded.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.foo {
content: "Foo-Bar-Baz-Qux";
}
2 changes: 2 additions & 0 deletions spec/libsass-closed-issues/issue_988/expected_output.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.foo {
content: "Foo-Bar-Baz-Qux"; }
13 changes: 13 additions & 0 deletions spec/libsass-closed-issues/issue_988/input.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
@function str-replace($string, $search, $replace: '') {
$index: str-index($string, $search);
@if $index {
@return str-slice($string, 1, $index - 1) + $replace +
str-replace(str-slice($string, $index + str-length($search)), $search, $replace);
}
@return $string;
}

$string: 'Foo Bar Baz Qux';
.foo {
content: str-replace($string, ' ', '-');
}

0 comments on commit 971c244

Please sign in to comment.