kiwix / java-libkiwix

Libkiwix binding for Java & Kotlin
https://central.sonatype.com/artifact/org.kiwix/libkiwix
GNU General Public License v3.0
3 stars 4 forks source link

Added new test cases for latest wrapper #30

Closed MohitMaliFtechiz closed 1 year ago

MohitMaliFtechiz commented 1 year ago

Fixes #29

In this PR we are adding new test cases for latest wrapper.

kelson42 commented 1 year ago

@MohitMaliFtechiz This PR has to be based on #27, I don't understand how this can work otherwise.

MohitMaliFtechiz commented 1 year ago

@MohitMaliFtechiz This PR has to be based on #27, I don't understand how this can work otherwise.

@kelson42 , i have made this branch from #27 and after that added new test cases in it, Once #27 is merged i'll re base this PR on main branch.

MohitMaliFtechiz commented 1 year ago

currently test cases are failing of because Linux libzim tar file containing 0 bytes .so file, so i have open a ticket for it in libzim https://github.com/openzim/libzim/issues/772 .

MohitMaliFtechiz commented 1 year ago

For now i have made this branch from https://github.com/kiwix/java-libkiwix/pull/31 to avoid the build failure because of linux zim file.

MohitMaliFtechiz commented 1 year ago

@mgautierfr , I am getting some errors while adding new test cases, can you please help me out on these errors.

kelson42 commented 1 year ago

@mgautierfr any update?

mgautierfr commented 1 year ago

@MohitMaliFtechiz First problem (setPtr) is fixed. But there is something wrong in the build system. I've spend a lot of time try to fix a crash in java interpreter and it was because the test was using a old version of the java .class definition (I think). I suppose that buildsystem doesn't detect correctly that .class have changed and don't update the one in the test directory.

I'm looking for the two others issues.

But on my side, I face a new test failure where the illustration data is not equal to expected (test.java:137). It is probably because the String constructor interpret the bytes (and probably stop at first \0).

codecov-commenter commented 1 year ago

Codecov Report

:exclamation: No coverage uploaded for pull request base (main@66ebc4e). Click here to learn what that means. Patch has no changes to coverable lines.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #30 +/- ## ======================================= Coverage ? 42.39% Complexity ? 18 ======================================= Files ? 24 Lines ? 92 Branches ? 6 ======================================= Hits ? 39 Misses ? 51 Partials ? 2 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

mgautierfr commented 1 year ago

The branch now compile and tests are passing. Let's merge it and move on with a new iteration.