public function AssetFactoryTest::testFilter

File

drupal/core/vendor/kriswallsmith/assetic/tests/Assetic/Test/Factory/AssetFactoryTest.php, line 107

Class

AssetFactoryTest

Namespace

Assetic\Test\Factory

Code

public function testFilter() {
  $this->fm
    ->expects($this
    ->once())
    ->method('get')
    ->with('foo')
    ->will($this
    ->returnValue($this
    ->getMock('Assetic\\Filter\\FilterInterface')));
  $asset = $this->factory
    ->createAsset(array(), array(
    'foo',
  ));
  $this
    ->assertEquals(1, count($asset
    ->getFilters()), '->createAsset() adds filters');
}