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 readability of test cases in core package #48

Open
gunnsth opened this issue Mar 15, 2019 · 0 comments
Open

Improve readability of test cases in core package #48

gunnsth opened this issue Mar 15, 2019 · 0 comments
Labels
core Package core tests

Comments

@gunnsth
Copy link
Contributor

gunnsth commented Mar 15, 2019

The goal is to make the tests more clear and easier to read as well as improve coverage.
Steps:

  • Go through the tests and for each function define the inputs and expected outputs.
  • Use testify to improve readability
  • Process each testcase (t.Run) and compare to expected value with assert.Equal / assert.NoError etc
  • Go through and add tests if any obvious test cases that can be added.

Currently the unit test coverage is [v3]:
$ go test -cover .
ok github.com/unidoc/unidoc/pdf/core 0.214s coverage: 48.7% of statements

whereas with cross-package tests the coverage is ~63.85% according to codecov.io.

@gunnsth gunnsth transferred this issue from unidoc/unidoc May 24, 2019
@gunnsth gunnsth added tests core Package core labels Jun 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Package core tests
Projects
None yet
Development

No branches or pull requests

1 participant