Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

[android] Implement android test runner for core unit tests #13617

Merged
merged 2 commits into from
Jan 10, 2019

Conversation

alexshalamov
Copy link
Contributor

Private APIs from android_runtime.so are no longer accessible, thus, core unit tests are segfaulting on android platform.

This PR introduces simple unit test runner and VM initialization code that can be reused for benchmark tests.

@alexshalamov
Copy link
Contributor Author

Most of the tests are passing, except:

  • Annotations.AntimeridianAnnotationLarge (pixel diff)
  • Expression.IsExpression (for some reason loads style outside of fixtures)
  • Memory.* (have to figure out)
  • Map.Offline (hangs when network status changes to online)

make run-android-core-test-arm-v8--Map.Offline:Memory.*:Annotations.AntimeridianAnnotationLarge:Expression.IsExpression

Copy link
Member

@tobrun tobrun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is amazing and long overdue! thank you for picking this up @alexshalamov.
Once this is merged we should try setting up a CI bot with this.

@alexshalamov alexshalamov force-pushed the alexshalamov_fix_core_android_unittests branch from 4104767 to d8cc12b Compare December 21, 2018 07:48
platform/android/src/test/runtime.cpp Outdated Show resolved Hide resolved
@alexshalamov alexshalamov force-pushed the alexshalamov_fix_core_android_unittests branch from d8cc12b to d909e19 Compare January 8, 2019 13:59
@alexshalamov
Copy link
Contributor Author

@kkaefer There are few failing cases due to small pixel mismatch differences in rendering, I couldn't figure out how to align all platforms to produce stable results. I've added d909e19 to filter-out some of the failures. Is this fine or maybe you would have better idea how to tackle it?

@alexshalamov alexshalamov force-pushed the alexshalamov_fix_core_android_unittests branch 2 times, most recently from 3117565 to 5bcea50 Compare January 10, 2019 14:03
@alexshalamov alexshalamov force-pushed the alexshalamov_fix_core_android_unittests branch from 5bcea50 to 2e00a87 Compare January 10, 2019 16:21
@alexshalamov alexshalamov merged commit d1b386e into master Jan 10, 2019
@alexshalamov alexshalamov deleted the alexshalamov_fix_core_android_unittests branch January 11, 2019 07:16
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Android Mapbox Maps SDK for Android
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants