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

Improve test coverage #3984

Open
curbengh opened this issue Dec 18, 2019 · 1 comment
Open

Improve test coverage #3984

curbengh opened this issue Dec 18, 2019 · 1 comment
Labels

Comments

@curbengh
Copy link
Contributor

@curbengh curbengh commented Dec 18, 2019

Check List

Please check followings before submitting a new feature request.

  • I have already read Docs page
  • I have already searched existing issues

Feature Request

This repo's unit test coverage currently stands at Coverage Status.

For anyone who is interested in improving it, there are a few ways:

  1. Search for "missing-unit-test" to locate functions that haven't been covered.
  2. Click on the coverage badge link and it shows all the relevant lines.
  3. Line coverage report is also shown in the CI job log.

hexo-util Coverage Status also needs help.

@NoahDragon NoahDragon mentioned this issue Dec 18, 2019
21 of 56 tasks complete
@seaoak

This comment has been minimized.

Copy link
Member

@seaoak seaoak commented Dec 20, 2019

@curbengh Thank you for nice waking-up call!

I checked a "missing-unit-test" point of hexo-util.
https://github.com/hexojs/hexo-util/blob/master/test/highlight.spec.js#L172

I found that highlight() of hexo-util might not work well for illegal syntax codes.
highlight() of highlightjs package will throw an exception if source text is illegal syntax codes.
https://highlightjs.readthedocs.io/en/latest/api.html#highlight-languagename-code-ignore-illegals-continuation

But hexo-util/lib/highlight.js might not consider that case.

I continue to investigate this issue (and make new issue in the repo of hexo-util).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.