From 448404953fa68c9b3a5b031992a5fb4a26dce57d Mon Sep 17 00:00:00 2001 From: Alex Risch Date: Thu, 15 Feb 2024 08:29:55 -0700 Subject: [PATCH] Detox: Corrected Android build --- example/android/app/build.gradle | 4 +++- example/e2e/utils/createConversation.ts | 1 + example/e2e/utils/sendMessage.ts | 4 ++++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/example/android/app/build.gradle b/example/android/app/build.gradle index 33e64fb04..f2bdf4b52 100644 --- a/example/android/app/build.gradle +++ b/example/android/app/build.gradle @@ -276,7 +276,9 @@ dependencies { // For loading .env implementation project(':react-native-config') // For Detox - androidTestImplementation 'com.wix:detox:+' + androidTestImplementation('com.wix:detox:+'){ + exclude module: "protobuf-lite" + } } apply from: new File(["node", "--print", "require.resolve('@react-native-community/cli-platform-android/package.json')"].execute(null, rootDir).text.trim(), "../native_modules.gradle"); diff --git a/example/e2e/utils/createConversation.ts b/example/e2e/utils/createConversation.ts index 99acfadda..127e70e1a 100644 --- a/example/e2e/utils/createConversation.ts +++ b/example/e2e/utils/createConversation.ts @@ -9,6 +9,7 @@ export const createConversation = async () => { '0xc93C111dcb2Df6Bb25a3F9035D5cd47bDc0381d0' ) await element(by.id('start-conversation-button')).tap() + await element(by.id('start-conversation-button')).tap() await waitFor(element(by.id('conversation-screen'))) .toBeVisible() .withTimeout(15000) diff --git a/example/e2e/utils/sendMessage.ts b/example/e2e/utils/sendMessage.ts index 9d026954e..531175d49 100644 --- a/example/e2e/utils/sendMessage.ts +++ b/example/e2e/utils/sendMessage.ts @@ -4,8 +4,12 @@ export const sendMessage = async (message: string) => { await waitFor(element(by.id('conversation-screen'))) .toBeVisible() .withTimeout(15000) + await waitFor(element(by.id('message-input'))) + .toBeVisible() + .withTimeout(15000) await element(by.id('message-input')).typeText(message) await element(by.id('send-message-button')).tap() + await element(by.id('send-message-button')).tap() await waitFor(element(by.id(/^conversation-message-.*/))) .toBeVisible()