Skip to content

Commit 63172a1

Browse files
@W-21933885: [MSDK Android] App Attestation Implementation (Add Debugging Notes For Test Investigation)
Added commented debugging notes to track test failures and crashes encountered during attestation test development: - LoginViewModelTest.kt: Added NullPointerException note for jwtFlow_Changes_loginUrl test showing SalesforceKeyGenerator.getSHA256Hash crash with null string - IDPAuthCodeHelperTest.kt: Added ANR crash note and removed unused Ignore import - LoginActivityScenarioTest.kt: Added native crash stack trace from Bluetooth service (system/gd/stack_manager.cc) affecting testWebviewSettings test These notes document issues encountered during test execution and will aid in future debugging and test stabilization efforts.
1 parent 261f874 commit 63172a1

3 files changed

Lines changed: 30 additions & 1 deletion

File tree

libs/test/SalesforceSDKTest/src/com/salesforce/androidsdk/auth/LoginViewModelTest.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,9 @@ class LoginViewModelTest {
193193
assertTrue(viewModel.loginUrl.value!!.contains(newCodeChallenge))
194194
}
195195

196+
// @Ignore
197+
// java.lang.NullPointerException: Attempt to invoke virtual method 'byte[] java.lang.String.getBytes(java.nio.charset.Charset)' on a null object reference
198+
// at com.salesforce.androidsdk.security.SalesforceKeyGenerator.getSHA256Hash(SalesforceKeyGenerator.java:130)
196199
@Test
197200
fun jwtFlow_Changes_loginUrl() {
198201
val server = viewModel.selectedServer.value!!

libs/test/SalesforceSDKTest/src/com/salesforce/androidsdk/auth/idp/IDPAuthCodeHelperTest.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ import org.junit.Assert.assertEquals
4646
import org.junit.Assert.assertFalse
4747
import org.junit.Assert.assertNull
4848
import org.junit.Assert.assertTrue
49-
import org.junit.Ignore
5049
import org.junit.Test
5150
import org.junit.runner.RunWith
5251
import java.net.URI
@@ -125,6 +124,8 @@ class IDPAuthCodeHelperTest {
125124
)
126125
}
127126

127+
// Your app crashed due to an ANR. Take a look at your logs to dig deeper.
128+
// @Ignore
128129
@OptIn(ExperimentalCoroutinesApi::class)
129130
@Test
130131
fun idpAuthCodeHelper_getAuthorizationPathForSP_whenCreateAppAttestationReturnsNull_excludesAttestationFromQuery() = runTest {

libs/test/SalesforceSDKTest/src/com/salesforce/androidsdk/ui/LoginActivityScenarioTest.kt

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,31 @@ class LoginActivityScenarioTest {
175175
}
176176
}
177177

178+
// *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
179+
// Build fingerprint: 'google/sdk_gphone64_arm64/emu64a:15/AE3A.240806.043/12960925:userdebug/dev-keys'
180+
// Revision: '0'
181+
// ABI: 'arm64'
182+
// Timestamp: 2026-04-24 14:50:27.342453036-0700
183+
// Process uptime: 0s
184+
// Cmdline: com.google.android.bluetooth
185+
// pid: 8824, tid: 8843, name: bt_stack_manage >>> com.google.android.bluetooth <<<
186+
// uid: 1002
187+
// tagged_addr_ctrl: 0000000000000001 (PR_TAGGED_ADDR_ENABLE)
188+
// pac_enabled_keys: 000000000000000f (PR_PAC_APIAKEY, PR_PAC_APIBKEY, PR_PAC_APDAKEY, PR_PAC_APDBKEY)
189+
// signal 6 (SIGABRT), code -1 (SI_QUEUE), fault addr --------
190+
// Abort message: 'system/gd/stack_manager.cc:57 StartUp: Can't start stack, last instance: starting HciHal'
191+
// x0 0000000000000000 x1 000000000000228b x2 0000000000000006 x3 0000007a0c4d87e0
192+
// x4 73521f3634396262 x5 73521f3634396262 x6 73521f3634396262 x7 7f7f7f7f7f7f7f7f
193+
// x8 00000000000000f0 x9 0000007cab2eb468 x10 ffffff80fffffb9f x11 0000000000000000
194+
// x12 0000007a0c4d76f0 x13 0000000000000059 x14 0000007a0c4d8938 x15 000182e65e501381
195+
// x16 0000007cab39aff8 x17 0000007cab3851c0 x18 00000078f8de8088 x19 0000000000002278
196+
// x20 000000000000228b x21 00000000ffffffff x22 0000007a1160e180 x23 0000000000000024
197+
// x24 00000078fb43e6c8 x25 0000007a0c4d8da0 x26 0000007a0c4d8938 x27 0000007a0c4d9a80
198+
// x28 00000078fbf67d40 x29 0000007a0c4d8860
199+
// lr 0000007cab3236a4 sp 0000007a0c4d87c0 pc 0000007cab3236d4 pst 0000000000001000
200+
// 22 total frames
201+
// backtrace:
202+
// @Ignore
178203
@Test
179204
fun testWebviewSettings() {
180205
launch<LoginActivity>(

0 commit comments

Comments
 (0)