Update template json to return created_at and updated_at. Also fixed a bug where updated_at was not being added to the templates_history model.

This commit is contained in:
Nicholas Staples
2016-05-19 17:02:55 +01:00
parent e0f6b4e571
commit 1797d9360b
4 changed files with 8 additions and 1 deletions

View File

@@ -91,5 +91,7 @@ def test_all_versions_of_template(notify_api, sample_template):
json_resp = json.loads(resp.get_data(as_text=True))
assert len(json_resp['data']) == 3
assert json_resp['data'][0]['content'] == newest_content
assert json_resp['data'][0]['updated_at']
assert json_resp['data'][1]['content'] == newer_content
assert json_resp['data'][1]['updated_at']
assert json_resp['data'][2]['content'] == old_content