Skip to content

Add Android sample unit tests - #550

Merged
kiftio merged 4 commits into
mainfrom
07-30-add_android_sample_unit_tests
Sep 4, 2026
Merged

Add Android sample unit tests#550
kiftio merged 4 commits into
mainfrom
07-30-add_android_sample_unit_tests

Conversation

@kiftio

@kiftio kiftio commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

What changes are you making?

Add some initial unit tests for the android sample

How to test

platforms/android/samples/CheckoutKitAndroidDemo/gradlew -p platforms/android/samples/CheckoutKitAndroidDemo :app:testDebugUnitTest --console=plain

or dev android test

Before you merge

Important

  • I've added tests to support my implementation
  • I have read and agree with the Contribution Guidelines
  • I have read and agree with the Code of Conduct
  • I've updated the relevant platform README (platforms/swift/README.md and/or platforms/android/README.md)

Releasing a new Swift version?
  • I have bumped the version in ShopifyCheckoutKit.podspec
  • I have bumped the version in platforms/swift/Sources/ShopifyCheckoutKit/ShopifyCheckoutKit.swift
  • I have updated the SwiftPM/CocoaPods version snippets in platforms/swift/README.md (major version only)
Releasing a new Embedded Checkout Protocol version?
  • I have bumped embeddedCheckoutProtocolAndroid in platforms/android/gradle/libs.versions.toml
  • I have updated protocol/languages/kotlin/embedded-checkout-protocol/api/embedded-checkout-protocol.api if the public API changed
Releasing a new Android version?
  • I have bumped checkoutKitAndroid in platforms/android/gradle/libs.versions.toml
  • I have updated the Gradle/Maven version snippets in platforms/android/README.md

Tip

See the Contributing documentation for the full release process per platform.

kiftio commented Jul 30, 2026

Copy link
Copy Markdown
Contributor Author

@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch from 22a08df to eba8cec Compare July 31, 2026 08:52
@kiftio
kiftio force-pushed the 07-29-encrypt_android_demo_customer_tokens branch from 2bcc8f9 to 55e0ab3 Compare July 31, 2026 09:14
@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch 2 times, most recently from d997263 to b486e6e Compare August 3, 2026 12:37
@kiftio
kiftio force-pushed the 07-29-encrypt_android_demo_customer_tokens branch 2 times, most recently from 32bcaa2 to 72dca20 Compare August 3, 2026 13:29
@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch from b486e6e to 148e49a Compare August 3, 2026 13:29
@kiftio
kiftio force-pushed the 07-29-encrypt_android_demo_customer_tokens branch 2 times, most recently from 0a58dd7 to ae965f4 Compare August 3, 2026 13:48
@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch from 148e49a to ca708be Compare August 3, 2026 13:49
@kiftio
kiftio changed the base branch from 07-29-encrypt_android_demo_customer_tokens to graphite-base/550 August 4, 2026 10:22
@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch from ca708be to 8ca1552 Compare August 4, 2026 14:48
@kiftio
kiftio force-pushed the graphite-base/550 branch from ae965f4 to 65974a9 Compare August 4, 2026 14:48
@kiftio
kiftio changed the base branch from graphite-base/550 to 07-29-encrypt_android_demo_customer_tokens August 4, 2026 14:48
@kiftio
kiftio changed the base branch from 07-29-encrypt_android_demo_customer_tokens to graphite-base/550 August 4, 2026 15:21
@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch from 8ca1552 to fdbc1a8 Compare August 5, 2026 10:29
@kiftio
kiftio force-pushed the graphite-base/550 branch from 65974a9 to 03d0a9b Compare August 5, 2026 10:29
@kiftio
kiftio force-pushed the 08-05-setup_sample_lint_and_formatting branch from 6b9b36a to 1de829d Compare August 5, 2026 11:00
@kiftio
kiftio changed the base branch from 08-05-setup_sample_lint_and_formatting to graphite-base/550 August 6, 2026 08:19
@kiftio
kiftio force-pushed the graphite-base/550 branch from 1de829d to 639d85f Compare August 6, 2026 08:19
@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch from 53b09d3 to 78797cf Compare August 6, 2026 08:19
@kiftio
kiftio changed the base branch from graphite-base/550 to 08-05-enable_magic_number_check August 6, 2026 08:20
@kiftio
kiftio force-pushed the 08-05-enable_magic_number_check branch from 639d85f to 7b0d44f Compare August 6, 2026 15:35
@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch from 78797cf to 740e002 Compare August 6, 2026 15:36
@kiftio
kiftio changed the base branch from 08-05-enable_magic_number_check to graphite-base/550 August 7, 2026 10:20
Assisted-By: devx/a47337e5-f216-42b2-9a39-833b1582ddd4
@kiftio
kiftio force-pushed the 07-30-add_android_sample_unit_tests branch from 740e002 to 3c832f6 Compare September 3, 2026 11:21
@kiftio
kiftio changed the base branch from graphite-base/550 to main September 3, 2026 11:35
@kiftio
kiftio marked this pull request as ready for review September 3, 2026 11:54
@kiftio
kiftio requested a review from a team as a code owner September 3, 2026 11:54
@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown

Package Size

Platform Artifact Base Head Delta
Android release AAR 364.8 KiB 364.8 KiB 0 B
Android file breakdown
File Base Head Delta
classes.jar 388.4 KiB 388.4 KiB 0 B
res/layout/checkout_view_content.xml 2.6 KiB 2.6 KiB 0 B
res/layout/checkout_sheet_content.xml 2.0 KiB 2.0 KiB 0 B
res/values/values.xml 1.3 KiB 1.3 KiB 0 B
R.txt 1.2 KiB 1.2 KiB 0 B
AndroidManifest.xml 922 B 922 B 0 B
proguard.txt 798 B 798 B 0 B
res/drawable/close.xml 431 B 431 B 0 B
res/menu/checkout_menu.xml 354 B 354 B 0 B
META-INF/com/android/build/gradle/aar-metadata.properties 157 B 157 B 0 B

Measured from the PR base SHA and PR head SHA. The file breakdown shows uncompressed sizes within each package artifact, so individual files do not sum to the compressed artifact total. This comment reports package artifact sizes only; it is not a final app binary-size report.

@bitrise

bitrise Bot commented Sep 3, 2026

Copy link
Copy Markdown

Install this build

Open Tophat, select your target device, then click Install. Links open on the Mac running Tophat.

SDK Install
Kotlin Install with Tophat

Checkout Kit E2E results

Status Suite Target Platform OS version tag Device
kotlin-android kotlin android latest Google Pixel 9
Android 17.0


@Test
fun `does not compare an invalid payload`() {
val result = json.diffPayload("not json", "{\"value\": 1}", changedStyle)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

are we testing a json lib here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

we might undo this soon, but it's basically some custom code to highlight the change between events

@kiftio
kiftio merged commit ac510f4 into main Sep 4, 2026
36 checks passed
@kiftio
kiftio deleted the 07-30-add_android_sample_unit_tests branch September 4, 2026 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

#gsd:50662 Rebase Checkout Kit on UCP

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants