mobile-dev-inc / maestro

Painless Mobile UI Automation
https://maestro.mobile.dev/
Apache License 2.0
5.88k stars 281 forks source link

tapOn expo router Link behaves unexpected (navigates but not correct) #2106

Closed NorfeldtKnowit closed 1 month ago

NorfeldtKnowit commented 1 month ago

Is there an existing issue for this?

Steps to reproduce

# Navigate to Logbog
- scrollUntilVisible:
    element: "Gå til logbog"
- tapOn: "Gå til logbog"

# Verify Logbog page
- assertVisible: "Logbog"

Actual results

{/* LOG BOOK */}
<Link
  href="/(auth)/me/(slot)/logbook"
  asChild
  onPress={() => console.log('link pressed')}>
  <Pressable
    accessibilityLabel="Gå til logbog"
    accessibilityRole="link"
    className="m-4 rounded-br-3xl rounded-tl-3xl rounded-tr-3xl bg-blomme px-4 py-6 active:opacity-90"
    onPress={() => console.log('pressable pressed')}>
    <View className="flex-row items-center justify-between">
      <Text className="text font-fighter text-sand">LOGBOG</Text>
      <SvgRight color={theme.extend.colors.sand} />
    </View>
    <Text className="my-4 font-fighter-bold text-lg text-sand">
      Log dagens velvære og symptomer
    </Text>
  </Pressable>
</Link>

The console logs are not showing and it navigates to /(auth)/me/(slot)/ (the index page).

Expected results

When pressing it manually the logs shows and it navigates to /(auth)/me/(slot)/logbook.

Was expecting maestro to do the same

About app

This app is closed source react-native expo project. If need I should be able to make an open source demo, but hoping that there is an obvious reason for this behavior.

expo-env-info 1.2.0 environment info: System: OS: macOS 14.6.1 Shell: 5.9 - /bin/zsh Binaries: Node: 20.17.0 - ~/.volta/tools/image/node/20.17.0/bin/node Yarn: 1.22.22 - ~/.volta/tools/image/yarn/1.22.22/bin/yarn npm: 10.8.2 - ~/.volta/tools/image/node/20.17.0/bin/npm Managers: CocoaPods: 1.15.2 - /opt/homebrew/bin/pod SDKs: iOS SDK: Platforms: DriverKit 24.0, iOS 18.0, macOS 15.0, tvOS 18.0, visionOS 2.0, watchOS 11.0 IDEs: Xcode: 16.0/16A242d - /usr/bin/xcodebuild npmPackages: expo: ^51.0.37 => 51.0.38 expo-router: ~3.5.14 => 3.5.23 react: 18.2.0 => 18.2.0 react-dom: 18.2.0 => 18.2.0 react-native: 0.74.5 => 0.74.5 react-native-web: ~0.19.10 => 0.19.12 Expo Workflow: managed

About environment

System: OS: macOS 14.6.1 (arm64) Shell: 5.9 - /bin/zsh maestro: 1.39.0 openjdk 23 2024-09-17 OpenJDK Runtime Environment Homebrew (build 23) OpenJDK 64-Bit Server VM Homebrew (build 23, mixed mode, sharing)

Logs

Logs ``` ?? ```

Maestro version

1.39.0

How did you install Maestro?

Homebrew

Anything else?

Screenshot 2024-10-22 at 11 05 21
linear[bot] commented 1 month ago

MA-2383 tapOn expo router Link behaves unexpected (navigates but not correct)

NorfeldtKnowit commented 1 month ago

okay, I think I got something, when it is pressing it when it’s barely visible it produce the bug.

image

but if I let it scroll more down and then press it then it works

image

github-actions[bot] commented 3 weeks ago

This issue has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar problem, please file a new issue. Make sure to follow the template and provide all the information necessary to reproduce the issue. Thank you for helping keep us our issue tracker clean!