-
Notifications
You must be signed in to change notification settings - Fork 87
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
Integration test coverage #329
Conversation
Codecov Report
@@ Coverage Diff @@
## v3 #329 +/- ##
==========================================
+ Coverage 38.54% 56.75% +18.2%
==========================================
Files 122 144 +22
Lines 23167 25098 +1931
==========================================
+ Hits 8930 14244 +5314
+ Misses 12956 10488 -2468
+ Partials 1281 366 -915
Continue to review full report at Codecov.
|
145089b
to
f9882d0
Compare
if err != nil { | ||
return err | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove empty line for consistency.
The package does work as intended when setting all the environment variables. The code looks great to me. I've added a couple of minor changes and suggestions. The only other suggestion would be to maybe add a function similar to the readPDF function in unicli (https://github.com/unidoc/unicli/blob/master/pdf/utils.go#L18) so that we don't repeat code when reading a PDF file (read, decrypt, get number of pages etc...). This is not really related to this PR because this function would be added in another package in unidoc but would improve the code here as well. Just something to take into consideration for the future. |
@adrg I have addressed all review comments, please take another look. |
@gunnsth All the review points have been addressed. Tested again after pulling the new commits. Everything works as intended. 👍 |
Package e2etest implements integration tests with a small test corpus (externally provided). It currently has two tests:
In the future we will add more integration test coverage and validation that the output is as expected. The current integration tests only ensure that there are no errors in loading, and outputing.
Added to Jenkinsfile to run in automatic builds and test coverage measurements. The test coverage is now obtained with
which measures the test coverage of all packages on all other packages within the projects, i.e. includes unit and integration tests.
Running the e2etests integration tests requires setting environment variables: