Permalink
Browse files

test case for LessphpFilter::setPresets

  • Loading branch information...
1 parent fc63b6d commit 8b2f0492da861c8b7a3bd6663135e1533b4e00fa @kastaneda kastaneda committed Apr 4, 2012
Showing with 14 additions and 0 deletions.
  1. +14 −0 tests/Assetic/Test/Filter/LessphpFilterTest.php
@@ -54,4 +54,18 @@ public function testImport()
$this->assertEquals($expected, $asset->getContent(), '->filterLoad() sets an include path based on source url');
}
+
+ public function testPresets()
+ {
+ $asset = new StringAsset('.foo { color: @bar }');
+ $asset->load();
+
+ $this->filter->setPresets(array(
+ 'bar' => 'green'
+ ));
+
+ $this->filter->filterLoad($asset);
+
+ $this->assertEquals(".foo { color:green; }\n", $asset->getContent(), '->setPresets() to pass variables into lessphp filter');
+ }
}

0 comments on commit 8b2f049

Please sign in to comment.