def test_spartacus_and_static_match(self):
     middleware = CSPMiddleware()
     sources = middleware.get_sources()
     eq_(sources, ('http://webpay.dev',))
 def test_with_spartacus(self):
     middleware = CSPMiddleware()
     sources = middleware.get_sources()
     eq_(set(sources), set(['http://webpay.dev', 'http://spartacus.dev']))
 def test_without_spartacus(self):
     del settings.SPARTACUS_STATIC
     middleware = CSPMiddleware()
     sources = middleware.get_sources()
     eq_(sources, ('http://webpay.dev',))
Beispiel #4
0
 def test_spartacus_and_static_match(self):
     middleware = CSPMiddleware()
     sources = middleware.get_sources()
     eq_(sources, ('http://webpay.dev', ))
Beispiel #5
0
 def test_with_spartacus(self):
     middleware = CSPMiddleware()
     sources = middleware.get_sources()
     eq_(set(sources), set(['http://webpay.dev', 'http://spartacus.dev']))
Beispiel #6
0
 def test_without_spartacus(self):
     del settings.SPARTACUS_STATIC
     middleware = CSPMiddleware()
     sources = middleware.get_sources()
     eq_(sources, ('http://webpay.dev', ))