Paparazzi app for android8/15/2023 ![]() We are updating the application locale at runtime using #updateConfiguration(, ), we had everything mocked in tests with MockK, but after adding Paparazzi the mocking doesn't work anymore, there are two errors we see: ![]() Meanwhile, I worked around the two issues above, but there's actually a third one I didn't notice before. I agree, ideally we'd be using a logging library, but it's not feasible changing this right now. Not sure if this is something commonly encountered, but does anyone have some suggestions on how to best approach the above issues? □ Another solution I see is just to create a separate module only for the screenshot tests, but that's kind of annoying, since we have several modules xD.Īnyway, from what I could figure out, these issues arise because layoutlib pulls in a reimplementation of the Android framework, and that conflicts somehow with our tests. The first error I worked around by mocking Log with mockk, and I guess I could do something similar for the second error, but I feel like I am just patching the symptoms of a bigger problem. ![]() : Can't create handler inside thread Thread that has not called Looper.prepare()Īt android.os.CountDownTimer$1.(CountDownTimer.java:129)Īt android.os.CountDownTimer.(CountDownTimer.java:129) So I commented out our class.Ĭan't create handler inside thread Thread that has not called Looper.prepare() JNIHelp F 11-25 18:20:30 RegisterNatives failed for 'android/util/Log' aborting. JNIHelp F 11-25 18:20:30 : Method 'boolean (, int)' name or signature does not match It's worth nothing that we used to load our own class in the test classpath and just call println() in our implementation, but with that present and adding the paparazzi plugin, the screenshot tests don't even run, Gradle fails with the following: : 'int _native(int, int,, )'Īt _native(Native Method) One of the issues is that we have invocations in our tests that now fail.
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |