From 9a0da126e60a8d3d7bea55066de73eae3eadc82e Mon Sep 17 00:00:00 2001 From: Francesco Siddi Date: Tue, 18 Sep 2018 15:14:27 +0200 Subject: [PATCH] Fix failing tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Failure was due to a new ‘slug’ key in the link dict. --- tests/test_web/test_projects.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/test_web/test_projects.py b/tests/test_web/test_projects.py index a428c4f1..59487baf 100644 --- a/tests/test_web/test_projects.py +++ b/tests/test_web/test_projects.py @@ -40,7 +40,7 @@ class ProjectTest(AbstractPillarTest): navigation_links = project_navigation_links(project, api=api) # We expect only one link to be in the list - links = [{'url': '/p/default-project/about', 'label': 'About'}] + links = [{'url': '/p/default-project/about', 'slug': 'about', 'label': 'About'}] self.assertListEqual(links, navigation_links) def test_project_navigation_links_pages_and_blog(self): @@ -89,9 +89,10 @@ class ProjectTest(AbstractPillarTest): project = find_project_or_404(self.project['url'], api=api) navigation_links = project_navigation_links(project, api=api) expected_list = [ - {'url': '/blog/', 'label': 'Blog'}, # Blog is the first element of the list (since it's added first) - {'url': '/p/default-project/about', 'label': 'About'}, - {'url': '/p/default-project/awards', 'label': 'Awards'}] + # Blog is the first element of the list (since it's added first) + {'url': '/blog/', 'slug': 'blog', 'label': 'Blog'}, + {'url': '/p/default-project/about', 'slug': 'about', 'label': 'About'}, + {'url': '/p/default-project/awards', 'slug': 'awards', 'label': 'Awards'}] self.assertListEqual(expected_list, navigation_links)