To test your mParticle local sample app:
To integrate a kit to a local sample app project:
Navigate to the app/libs folder using command
cd app/libs (you can use the Tab key to autocomplete the path).
cdkit-name or use the Tab key to add the path name to the kit repository name.
git checkoutbranch-name or
git checkout -bnew-branch-name.
project(':mparticle-android-integration-*replace-with-kit-name*').projectDir = new File('app/libs/mparticle-android-integration-replace-with-kit-name).
You can now test your kit integration. Place a breakpoint inside the kit’s
onCreate() and run the app in debug mode. If the kit is integrated, the breakpoint should trigger, indicating the kit is being initialized.
Due to the complexity of the multi-module configuration of the SDK, adding it directly as an operable module in the sample app is not currently supported. Different steps must be taken to build the SDK locally and add it as a dependency.
./gradlew publishReleaseLocal. This command creates a local snapshot of the SDK.
build.gradle.ktsfile, replace the original core implementation with yours. You can find the name in your local m2 folder. The dependency should contain the word “SNAPSHOT.” The complete dependency should be similar to the following:
You can now test your changes locally.
Was this page helpful?