def test_cssutils(self, walk_resources, _CSSUtils, putter): from van.static.cdn import extract extract(['r1', 'r2'], 'file:///path/to/local', yui_compressor=False, ignore_stamps=True, cssutils_minify=True) # comp was called _CSSUtils.assert_called_once_with(resolve_imports=False, minify=True) _CSSUtils().process.assert_called_once_with(walk_resources()) _CSSUtils().dispose.assert_called_once_with() # and putter with the result of _CSSUtils putter().put.assert_called_once_with(_CSSUtils().process())
def one(self, **kw): from van.static.cdn import _CSSUtils one = _CSSUtils(**kw) self._to_dispose.append(one) return one