You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@Test
fun addition_isCorrect() {
val wrapperLib = File("app/src/main/jniLibs/osx/libSeePlusPlus_Wrapper.jnilib")
System.load(wrapperLib.absolutePath)
var mCpp = SeePlusPlus()
val result = mCpp.Multiply(5, 1)
Assert.assertEquals(5, result)
}
Essentially, JUnit runs on the computer's platform, so having Android NDK-built libraries is of no use. Need to re-build these libraries 'natively' - using Mac/Linux/Windows.
A problem with running native code is that you often need to use the instrumentation tests to run unit tests.
Actually, in reality, you just need to compile your libraries for your platform (as junit runs on your computer's native platform).
The text was updated successfully, but these errors were encountered: