Test the library with a sample application

  1. First let's "build" the package by selecting "Build" from the Menu option and then select "Build Bundles/APK" and "Build APK" as shown in the below screenshot (Image 5).
  • Image 5

Sometimes the build Bundles/APK option would be disabled, in those scenarios you can perform it manually from the terminal using "gradlew clean build" as shown below (Image 6).

  • Image 6

  1. After it is built successfully, you will find the latest "Sample.debug.apk" file available in the "Sample-> build-> outputs->apk-> debug" folder.
  2. You can use this APK and run on any of the emulators to view the sample application of the library usage.
  3. Once the APK file is up running on the emulator you should be able to view the library behavior as shown below (Image 7).
  • Image 7

Until now we have selected a library, imported to Android studio, synced up and successfully run the sample Application using the APK file on the Emulator.

Discussion

3

0