Пример #1
0
 def test_find_dynamic_resource_no_dynamic(self):
     resource = Mock(resources={'/items': 'foo'})
     assert utils.find_dynamic_resource(resource) is None
Пример #2
0
 def test_find_dynamic_resource_no_resources(self):
     resource = Mock(resources=None)
     assert utils.find_dynamic_resource(resource) is None
Пример #3
0
 def test_find_dynamic_resource(self):
     resource = Mock(resources={'/items': 'foo', '/{id}': 'bar'})
     assert utils.find_dynamic_resource(resource) == 'bar'