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.

Opinions: Looks of the pytest docs?

See original GitHub issue

Since awhile now I feel that the documentation could use a face lift.

It seems to me it is not a single thing, it might be a bunch of small things/tweeks from some one who knows about design.

I’ve built the docs with the RTD theme (which I like) to try to give examples of what I’m trying to convey:

image

This is not bad, of course, but I have the feeling that the RTD theme is better:

image (1)

Here is some things that I think are better in the second screenshot:

  1. The overall font and styles seem better to read somehow (I can’t point my finger at what exactly makes it better).
  2. The function signature looks more like a header, as it should be I think.
  3. The keywords (re.search, re.escape) have a nice highlight; in the first screenshot they are easy to miss in the middle of the text.
  4. Nice use of colors to bring attention to some parts of the text (like the [source] link), without overusing colors.

Another example:

image (2) image (3)

The first screenshot looks outdated, while the second one looks more modern to me somehow.

Of course those are all impressions of someone with zero talent for design, so take that as it is.

I’m not proposing here we should go and adopt the RTD theme, but I was wondering if anybody feels the same way? Perhaps someone with an eye on design (or even a professional) can critically look at our styles and provide suggestions of good improvements?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:13
  • Comments:29 (26 by maintainers)

github_iconTop GitHub Comments

2reactions
nicoddemuscommented, Jun 1, 2020

So in the end we decided to ditch the customizations we had on the Flask theme and update it to the last official version (https://github.com/pytest-dev/pytest/pull/6453).

Thanks everyone!

2reactions
blueyedcommented, Jan 26, 2020

Please vote this comment up if you like the Sphinx ReadTheDocs theme, and down if you are strongly opposed to it. Preview: https://docs.pytest.org/en/use-rtd-theme (PR https://github.com/pytest-dev/pytest/pull/6460).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Full pytest documentation
Demo of Python failure reports with pytest · Basic patterns and examples · Parametrizing tests · Working with custom markers · A session-fixture...
Read more >
5 Pytest Best Practices for Writing Great Python Tests
Table of Contents · Prefer mocker over mock · Parametrize the same behavior, have different tests for different behaviors · Don't modify fixture ......
Read more >
pytest Documentation - Read the Docs
When pytest goes to run a test, it looks at the parameters in that test function's signature, and then searches for fixtures.
Read more >
Effective Python Testing With Pytest
They look very much like normal Python functions. All of this makes the learning curve for pytest shallower than it is for unittest...
Read more >
Customer reviews: Python Testing with pytest - Amazon.com
It's a very slim volume for $35, especially considering that a lot of this information can be found on the internet or from...
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