You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Earlier, when getAttributes() was relevant only for iOS, I was using workaround described in detox-getprops package. Now, when we already have getAttributes available for android I was trying to refactor code to use new api for Android and I still can't due to the next issue:
12-24 10:22:31.433 7880 7951 I DetoxActionHandlers: at java.lang.Thread.run(Thread.java:920) 12-24 10:22:31.433 7880 7951 I DetoxActionHandlers: Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/android/material/slider/Slider; 12-24 10:22:31.433 7880 7951 I DetoxActionHandlers: at com.wix.detox.espresso.action.SliderAttributes.get(GetAttributesAction.kt:143)
adb logs from flipper
Test exception java.lang.reflect.InvocationTargetException at java.lang.reflect.Method.invoke(Native Method) at org.apache.commons.lang3.reflect.MethodUtils.invokeStaticMethod(MethodUtils.java:443) at org.apache.commons.lang3.reflect.MethodUtils.invokeStaticMethod(MethodUtils.java:405) at com.wix.invoke.types.ClassTarget.execute(ClassTarget.java:23) at com.wix.invoke.types.Target.invoke(Target.java:59) at com.wix.invoke.MethodInvocation.invoke(MethodInvocation.java:35) at com.wix.invoke.MethodInvocation.invoke(MethodInvocation.java:26) at com.wix.invoke.MethodInvocation.invoke(MethodInvocation.java:20) at com.wix.detox.adapters.server.InvokeActionHandler.handle(DetoxActionHandlers.kt:54) at com.wix.detox.adapters.server.ActionsExecutor$executeAction$$inlined$let$lambda$1.run(DetoxActionsDispatcher.kt:64) at android.os.Handler.handleCallback(Handler.java:938) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:236) at com.wix.detox.adapters.server.ActionsExecutor$1.run(DetoxActionsDispatcher.kt:50) at java.lang.Thread.run(Thread.java:923) Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/android/material/slider/Slider; at com.wix.detox.espresso.action.SliderAttributes.get(GetAttributesAction.kt:143) at com.wix.detox.espresso.action.GetAttributesAction.perform(GetAttributesAction.kt:35) at androidx.test.espresso.ViewInteraction$SingleExecutionViewAction.perform(ViewInteraction.java:16) at androidx.test.espresso.ViewInteraction.doPerform(ViewInteraction.java:65) at androidx.test.espresso.ViewInteraction.access$100(ViewInteraction.java:15) at androidx.test.espresso.ViewInteraction$1.call(ViewInteraction.java:3) at androidx.test.espresso.ViewInteraction$1.call(ViewInteraction.java:2) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at android.os.Handler.handleCallback(Handler.java:938) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:236) at android.app.ActivityThread.main(ActivityThread.java:7904) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:656) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:967) Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.android.material.slider.Slider" on path: DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/android.test.base.jar", zip file "/data/app/~~cKeisWq_XsZnxP1iccV_UA==/com.company_name_software.template.test-bk0vgB3hLCjmehCxsyFyiw==/base.apk", zip file "/data/app/~~HPlEJcsMIWP3D6_aFGB6iQ==/com.company_name_software.template-4FY6xvXPTEewNH2EYjhpTA==/base.apk"],nativeLibraryDirectories=[/data/app/~~cKeisWq_XsZnxP1iccV_UA==/com.company_name_software.template.test-bk0vgB3hLCjmehCxsyFyiw==/lib/arm64, /data/app/~~HPlEJcsMIWP3D6_aFGB6iQ==/com.company_name_software.template-4FY6xvXPTEewNH2EYjhpTA==/lib/arm64, /data/app/~~cKeisWq_XsZnxP1iccV_UA==/com.company_name_software.template.test-bk0vgB3hLCjmehCxsyFyiw==/base.apk!/lib/arm64-v8a, /data/app/~~HPlEJcsMIWP3D6_aFGB6iQ==/com.company_name_software.template-4FY6xvXPTEewNH2EYjhpTA==/base.apk!/lib/arm64-v8a, /system/lib64, /system_ext/lib64]] at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:207) at java.lang.ClassLoader.loadClass(ClassLoader.java:379) at java.lang.ClassLoader.loadClass(ClassLoader.java:312) ... 15 more
Device logs
(paste logs here)
Screenshots / Video
Located element.
Environment
Detox: 19.3.1
React Native: 0.63.2
Node: v14.18.2
Device: emulator @Pixel_3a_API_30
OS: Mac OS Monterey
Test-runner (select one): jest-circus
The text was updated successfully, but these errors were encountered:
Describe the bug
Earlier, when getAttributes() was relevant only for iOS, I was using workaround described in detox-getprops package. Now, when we already have getAttributes available for android I was trying to refactor code to use new api for Android and I still can't due to the next issue:
DetoxRuntimeError: Test Failed: com.google.android.material.slider.Slider 70 | (<any>await element(numberInputMatcher(inputName)).getAttributes()).text : 71 | // await getText(element(numberInputMatcher(inputName))) > 72 | console.log(await element(numberInputMatcher(inputName)).getAttributes()) | ^ 73 | (await element(numberInputMatcher(inputName)).atIndex(0).getAttributes()).text 74 | }
Expected behavior
Props object retrieved.
Detox Trace-Logs
Detox logs
(paste logs here)
Device logs (adb logcat)
12-24 10:22:31.433 7880 7951 I DetoxActionHandlers: at java.lang.Thread.run(Thread.java:920) 12-24 10:22:31.433 7880 7951 I DetoxActionHandlers: Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/android/material/slider/Slider; 12-24 10:22:31.433 7880 7951 I DetoxActionHandlers: at com.wix.detox.espresso.action.SliderAttributes.get(GetAttributesAction.kt:143)
adb logs from flipper
Test exception java.lang.reflect.InvocationTargetException at java.lang.reflect.Method.invoke(Native Method) at org.apache.commons.lang3.reflect.MethodUtils.invokeStaticMethod(MethodUtils.java:443) at org.apache.commons.lang3.reflect.MethodUtils.invokeStaticMethod(MethodUtils.java:405) at com.wix.invoke.types.ClassTarget.execute(ClassTarget.java:23) at com.wix.invoke.types.Target.invoke(Target.java:59) at com.wix.invoke.MethodInvocation.invoke(MethodInvocation.java:35) at com.wix.invoke.MethodInvocation.invoke(MethodInvocation.java:26) at com.wix.invoke.MethodInvocation.invoke(MethodInvocation.java:20) at com.wix.detox.adapters.server.InvokeActionHandler.handle(DetoxActionHandlers.kt:54) at com.wix.detox.adapters.server.ActionsExecutor$executeAction$$inlined$let$lambda$1.run(DetoxActionsDispatcher.kt:64) at android.os.Handler.handleCallback(Handler.java:938) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:236) at com.wix.detox.adapters.server.ActionsExecutor$1.run(DetoxActionsDispatcher.kt:50) at java.lang.Thread.run(Thread.java:923) Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/android/material/slider/Slider; at com.wix.detox.espresso.action.SliderAttributes.get(GetAttributesAction.kt:143) at com.wix.detox.espresso.action.GetAttributesAction.perform(GetAttributesAction.kt:35) at androidx.test.espresso.ViewInteraction$SingleExecutionViewAction.perform(ViewInteraction.java:16) at androidx.test.espresso.ViewInteraction.doPerform(ViewInteraction.java:65) at androidx.test.espresso.ViewInteraction.access$100(ViewInteraction.java:15) at androidx.test.espresso.ViewInteraction$1.call(ViewInteraction.java:3) at androidx.test.espresso.ViewInteraction$1.call(ViewInteraction.java:2) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at android.os.Handler.handleCallback(Handler.java:938) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:236) at android.app.ActivityThread.main(ActivityThread.java:7904) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:656) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:967) Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.android.material.slider.Slider" on path: DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/android.test.base.jar", zip file "/data/app/~~cKeisWq_XsZnxP1iccV_UA==/com.company_name_software.template.test-bk0vgB3hLCjmehCxsyFyiw==/base.apk", zip file "/data/app/~~HPlEJcsMIWP3D6_aFGB6iQ==/com.company_name_software.template-4FY6xvXPTEewNH2EYjhpTA==/base.apk"],nativeLibraryDirectories=[/data/app/~~cKeisWq_XsZnxP1iccV_UA==/com.company_name_software.template.test-bk0vgB3hLCjmehCxsyFyiw==/lib/arm64, /data/app/~~HPlEJcsMIWP3D6_aFGB6iQ==/com.company_name_software.template-4FY6xvXPTEewNH2EYjhpTA==/lib/arm64, /data/app/~~cKeisWq_XsZnxP1iccV_UA==/com.company_name_software.template.test-bk0vgB3hLCjmehCxsyFyiw==/base.apk!/lib/arm64-v8a, /data/app/~~HPlEJcsMIWP3D6_aFGB6iQ==/com.company_name_software.template-4FY6xvXPTEewNH2EYjhpTA==/base.apk!/lib/arm64-v8a, /system/lib64, /system_ext/lib64]] at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:207) at java.lang.ClassLoader.loadClass(ClassLoader.java:379) at java.lang.ClassLoader.loadClass(ClassLoader.java:312) ... 15 more
Device logs
(paste logs here)
Screenshots / Video
Located element.
Environment
jest-circus
The text was updated successfully, but these errors were encountered: