Update json structure for unit tests.

This commit is contained in:
Rebecca Law
2016-05-16 11:53:22 +01:00
parent fcf277c413
commit d4225de45e
3 changed files with 12 additions and 6 deletions

View File

@@ -203,9 +203,11 @@ def mock_get_aggregate_service_statistics(mocker):
@pytest.fixture(scope='function')
def mock_get_service_template(mocker):
def _get(service_id, template_id):
def _get(service_id, template_id, version=None):
template = template_json(
service_id, template_id, "Two week reminder", "sms", "Your vehicle tax is about to expire")
if version:
template.update({'version': version})
return {'data': template}
return mocker.patch(