Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Bugdown tests for !avatar syntax #1654

Closed
timabbott opened this issue Aug 18, 2016 · 0 comments
Closed

Add Bugdown tests for !avatar syntax #1654

timabbott opened this issue Aug 18, 2016 · 0 comments

Comments

@timabbott
Copy link
Member

I wrote tests for these, and the tests match what happens in production, but I get some really weird output running this in the test suite:

Running Bugdown test gravatar
Traceback (most recent call last):
  File "/home/tabbott/zulip/zerver/lib/test_runner.py", line 129, in run_test
    test_method()
  File "/home/tabbott/zulip/zerver/tests/test_bugdown.py", line 159, in test_bugdown_fixtures
    self.assertEqual(converted, test['expected_output'])
  File "/usr/lib/python2.7/unittest/case.py", line 513, in assertEqual
    assertion_func(first, second, msg=msg)
  File "/usr/lib/python2.7/unittest/case.py", line 924, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "/usr/lib/python2.7/unittest/case.py", line 410, in fail
    raise self.failureException(msg)
AssertionError: u'<p><img alt="\x02klzzwxh:0000\x03" class="message_body_gravatar" src="/avatar/ [truncated]... != u'<p><img alt="[email protected]" class="message_body_gravatar" src="/avatar/ [truncated]...
- <p><img alt="�klzzwxh:0000�" class="message_body_gravatar" src="/avatar/�klzzwxh:0000�?s=30" title="�klzzwxh:0000�"></p>
+ <p><img alt="[email protected]" class="message_body_gravatar" src="/avatar/[email protected]?s=30" title="[email protected]"></p>

Here's the code:
https://github.com/timabbott/zulip/commits/markdown-bugs

kkanahin added a commit to SmartPeople/zulip that referenced this issue Oct 19, 2016
- Put 'modal_link' and 'link' inline patterns after avatar inline pattern
  to correct applying them to parsed text.

Fixes:  zulip#1654
kkanahin added a commit to SmartPeople/zulip that referenced this issue Oct 19, 2016
- Put 'modal_link' and 'link' inline patterns after avatar inline pattern
  to correct applying them to parsed text.

Fixes:  zulip#1654
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants