-
Notifications
You must be signed in to change notification settings - Fork 186
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
New option: --external-css-file #35
Conversation
Fixes Bachmann1234#34. Missing bits: - diff-quality should probably also support --external-css-file - tests I'm also not very fond of duplicating some CSS rules between external-style.css and snippet_style.html.
A hint about the best way to test this would be nice. |
Testing in test integration is fine. The whole project is a pretty small flow. So I don't mind most of the tests being higher level. One thing to keep in mind is that I recently changed it so the tests dont look at CSS. This is because pygments changes its CSS from time to time and I got tired of fixing the tests for that. So will need to think of some way of checking the correct css was applied. Simply checking one of your classes is there would likely be enough. |
Pushed a test. I don't know how I feel about adding this feature to Some gentle encouragement could help. ;) |
@mgedmin Id certainly appreciate it. I mean you basically laid out the reasons. The test plan and quite frankly the implementation would be fairly similar. In fact you are part of the way there best I could tell :-P |
Test plan for diff-quality:
|
Ill review and likely merge this weekend. Release should be sometime in the next week or two as I am still hoping to get some feedback from people at edx about some major refactoring that happened |
👍 |
New option: --external-css-file
Ill release this in the next week or two. Feel free to harass me if I forget. |
This is released! https://pypi.python.org/pypi/diff_cover/0.9.0 |
Thanks @mgedmin for the PR and the detailed info on the test plan :-) |
Fixes #34.
This is a prototype that I expect to need to fix before it gets merged.
Missing bits:
I'm also not very fond of duplicating some CSS rules between external-style.css and snippet_style.html.
Test plan:
tox
(trieddetox
, but your test suite doesn't support parallel execution due to writing to the same hardcoded filenames!)virtualenv .venv && .venv/bin/pip install -e .
).venv/bin/diff-cover coverage.xml --html /tmp/diff-cover.html --external-css /tmp/diff-cover.css
/tmp/diff-cover.*
with a text editor and tried it out in a browser