Skip to content

Commit

Permalink
Fix bad test
Browse files Browse the repository at this point in the history
This fixes a test that was always returning true despite the fact that
one of the cases fails. This fixes the test, but one case still fails.
  • Loading branch information
willkg committed Mar 5, 2013
1 parent f846be3 commit de8b552
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions fjord/base/tests/test_browser.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@ def check_ua(self, case):
'platform', 'platform_version',
'mobile'])

assert (parsed == expected,
'UA Detection failed. UA="{0}", parsed="{1}" expected="{2}"'
.format(case['user_agent'], parsed, expected))
msg = ('UA Detection failed. UA="{0}", parsed="{1}" '
'expected="{2}"'.format(
case['user_agent'], parsed, expected))
assert parsed == expected, msg

def test_parse_ua(self):
"""Test that a suite of should-work user agents work."""
Expand Down

0 comments on commit de8b552

Please sign in to comment.