Skip to content

Commit

Permalink
add missing unittests
Browse files Browse the repository at this point in the history
  • Loading branch information
willforde committed Mar 13, 2018
1 parent a6710a5 commit 7f1c301
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/test_listing.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,8 +247,9 @@ def setUp(self):
self.base = listing.Context(listitem)
self.org_routes = dispatcher.registered_routes.copy()

# noinspection PyUnusedLocal
@route.Route.register
def test_callback(_):
def test_callback(_, test):
pass

self.test_callback = test_callback
Expand All @@ -267,7 +268,7 @@ def test_container(self):
"tests/test_listing/test_callback)")

def test_container_with_params(self):
self.base.container(self.test_callback, "test label", test=True)
self.base.container(self.test_callback, "test label", True, url="tester")
label, command = self.base[0]

self.assertEqual(label, "test label")
Expand All @@ -283,7 +284,7 @@ def test_script(self):
"tests/test_listing/test_callback)")

def test_script_with_params(self):
self.base.script(self.test_callback, "test label", test=True)
self.base.script(self.test_callback, "test label", True, url="tester")
label, command = self.base[0]

self.assertEqual(label, "test label")
Expand Down

0 comments on commit 7f1c301

Please sign in to comment.