def test_static_url(filename, expected): app = pretend.stub( static_dir=Warehouse.static_dir, static_path=Warehouse.static_path, ) assert fnmatch.fnmatch(static_url(app, filename), expected)
def test_static_url(filename, debug, expected): app = pretend.stub( config=pretend.stub( debug=debug, ), ) assert fnmatch.fnmatch(static_url(app, filename), expected)
def test_static_url(filename, expected): app = pretend.stub( config=pretend.stub( urls=pretend.stub( assets="/static/", ), ), ) assert fnmatch.fnmatch(static_url(app, filename), expected)
def test_static_url(filename, expected): app = pretend.stub(config=pretend.stub(urls=pretend.stub( assets="/static/", ), ), ) assert fnmatch.fnmatch(static_url(app, filename), expected)