コード例 #1
0
ファイル: test_bundle.py プロジェクト: thatguystone/webassets
 def test_pass_down_env(self):
     """[Regression] When a root *container* bundle is connected
     to an environment, the child bundles do not have to be.
     """
     child = Bundle('1', '2')
     child.env = None
     root = self.MockBundle(child)
     root.env = self.m
     # Does no longer raise an "unconnected env" exception
     assert root.urls() == ['/1', '/2']
コード例 #2
0
 def test_pass_down_env(self):
     """[Regression] When a root *container* bundle is connected
     to an environment, the child bundles do not have to be.
     """
     child = Bundle('1', '2')
     child.env = None
     root = self.MockBundle(child)
     root.env = self.env
     # Does no longer raise an "unconnected env" exception
     assert root.urls() == ['/1', '/2']
コード例 #3
0
ファイル: test.py プロジェクト: bryanchow/webassets
 def mkbundle(self, *a, **kw):
     b = Bundle(*a, **kw)
     b.env = self.env
     return b
コード例 #4
0
 def mkbundle(self, *a, **kw):
     b = Bundle(*a, **kw)
     b.env = self.env
     return b