question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unit test failures

See original GitHub issue

I got one failed test while trying to package jello for Debian:

======================================================================
FAIL: test_dict_html (tests.test_create_json.MyTests)
Test self.dict_sample html output
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build/jello-1.4.2/.pybuild/cpython3_3.9_jello/build/tests/test_create_json.py", line 450, in test_dict_html
    self.assertEqual(self.json_out.html_output(output), self.expected)
AssertionError: '<div[72 chars]125%; margin: 0;"><span></span>{\n  <span styl[1171 chars]v>\n' != '<div[72 chars]125%;"><span></span>{\n  <span style="color: #[1160 chars]v>\n'
Diff is 1505 characters long. Set self.maxDiff to None to see it.

----------------------------------------------------------------------
Ran 188 tests in 0.314s

FAILED (failures=1)

It looks like the HtmlFormatter class in Pygments 2.7.1 adds an additional margin: 0 property to the <pre> style.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:14 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
kellyjonbrazilcommented, Jun 23, 2021

Ok, v1.4.3 is now up. Let me know if you need anything else. Happy to help!

1reaction
roehlingcommented, Jun 23, 2021

Well then it was (good|bad) luck that we ran into this issue, because Pygments would likely have been updated to 2.9.0 already if it were not for the ongoing Bullseye release freeze.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why are unit tests failing seen as bad?
A test failure may indicate a planned feature under TDD which isn't yet implemented; or it may indicate a known issue which has...
Read more >
How to write good unit tests: Write failing tests first
To write reliable unit tests, always start writing a failing test. And make sure it fails for the right reasons. Follow the Red,...
Read more >
The Difference Between Failure and Error in JUnit | Baeldung
Both failure and error in JUnit tests indicate an undesired situation, but their semantics are different. Failures notify of an invalid test ...
Read more >
Are Your Unit Tests Failing and You Don't Know Why? - Parasoft
To do so, it's important to understand what it means when a unit test fails. It boils down to three reasons, with simple...
Read more >
What causes a unit test to fail? | Python - DataCamp
A passing test is good news as it means that your function works as expected. The character F stands for a failing test....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found