Open choldgraf opened 4 years ago
What you describe in this issue is the exact structure of the current tests so my guess is that you implemented it without closing the issue.
Let me know if other stuff need to be taken care of before closing.
I'm going to hijack update this issue to reflect the current state of testing, and what I see as needing improvement. Others please feel free to add to this list:
sidebar_includehidden
, navigation_depth
, collapse_navigation
, and show_nav_level
(and navigation_startdepth
, if #1241 ever gets sorted out). Bug reports like #1551 show that we're not testing that well enough.I just want to chime in here that I think this is a super important issue if we ever want to get PyData Theme to a stable release. Based on my experience working on the theme over the past several months, I would say it's a little too easy to break something while trying to fix something else.
Some of the kinds of tests I would like to add via Playwright are things like "does this button have a focus ring", "is the focus ring still visible when the button is hovered with a mouse", etc.
some work on that is underway as we speak. The initial target is #1583 but the plan is that the playwright tests for that can be a template for similar tests for other UI elements / components.
Now that #227 is merged we have a basic testing infrastructure set up for the theme. This will let us test the HTML outputs that are generated by the theme, using BeautifulSoup.
We should add more tests for the following things:
Make sure that...
:numbered:
flagFor each of these, I think the easiest thing to do is:
beautifulsoup
to select the subset of a page we want to testfile_regression
to test its structure against a reference we have committed to the tests folderSee the contributing documentation for some guidelines on how this works!
Note that I'm also making this issue because I'll likely go on paternity leave sometime in the next several weeks so probably will not be able to personally do this but I am happy to help advise and guide others!