def testGetAssetTag(self): asset = get_test_asset() url = default_asset_cache.get_url(asset) self.assertEqual( Template("{% load assets %}{% get_asset asset as asset_url %}{{asset_url}}").render(Context({ "asset": asset, })), url, )
def testFileAsset(self): asset = FileAsset(File(open(get_test_asset().get_path(), "rb"))) self.assertAssetWorks(asset)
def testStaticAsset(self): self.assertAssetWorks(get_test_asset())