Git Product home page Git Product logo

droidtestrec's People

Contributors

jbaginski avatar vpedak avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

droidtestrec's Issues

Crashes on latest Android Studio 2.1 with Android N preview

I know webviews aren't supported but it'd be nice not to crash.

java.lang.AbstractMethodError: abstract method "android.view.View android.webkit.WebViewProvider$ViewDelegate.findFocus(android.view.View)"
at android.webkit.WebView.findFocus(WebView.java:2633)
at android.view.ViewGroup.findFocus(ViewGroup.java:1050)
at android.view.ViewGroup.findFocus(ViewGroup.java:1050)
at android.view.ViewGroup.findFocus(ViewGroup.java:1050)
at android.view.ViewGroup.findFocus(ViewGroup.java:1050)
at android.view.ViewGroup.findFocus(ViewGroup.java:1050)
at android.view.ViewGroup.findFocus(ViewGroup.java:1050)
at android.view.ViewGroup.findFocus(ViewGroup.java:1050)
at android.view.ViewGroup.findFocus(ViewGroup.java:1050)
at android.view.ViewRootImpl$ViewRootHandler.handleMessage(ViewRootImpl.java:3520)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:6066)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:770)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:660)

Test running failed: Instrumentation run failed due to 'java.lang.AbstractMethodError'

duplicate entry: com/vpedak/testsrecorder/plugin/core/Templates.class

Error:Execution failed for task ':candroid:transformClassesWithJarMergingForDebug'.
> com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: com/vpedak/testsrecorder/plugin/core/Templates.class

I'm seeing this error with the latest version of the plugin on android studio 2.1.

edit text changes should wait till loses focus before generating action

great plugin, thanks for building it! Would be nice to wait until loses focus or timer to avoid generating multiple unnecessary lines

    // Set text to 'r' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("r"));

    // Set text to 'ri' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("ri"));

    // Set text to 'ric' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("ric"));

    // Set text to 'rich' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("rich"));

    // Set text to 'riche' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("riche"));

    // Set text to 'rich' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("rich"));

    // Set text to 'richa' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("richa"));

    // Set text to 'richar' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("richar"));

    // Set text to 'richard' in DollyEditText with id R.id.edit_text_email
    onView(withId(R.id.edit_text_email)).perform(replaceText("richard"));

record error

When I click record button.It does nothing.
Log message:
NoSuchMethodError: java.io.File.toPath()Ljava/nio/file/Path;

NoClassDefFoundError AndroidTestRunConfigurationType

Hello Slava,

While running the app (at least with the latest version of Android Studio) I will get the following error: NoClassDefFoundError: org/jetbrains/android/run/testing/AndroidTestRunConfigurationType

It looks like this class is needed by ToolsTestsRecorderAction. Which plugin do I have to download? I couldn't found it in my project.

Thank you for answering.

Error while Installing APK

Showing error
The APK file /Users/.../app/build/outputs/apk/app-debug-androidTest-unaligned.apk does not exist on disk.

Use precompiled APK

The robotium recorder is cool because you can just pass an APK and begin recording. The droidtestrec Android Studio plugin appears to require compiling the app before you can record.

Any thoughts on adding an option to specify the precompiled APK?

PluginException on android studio canary channel (2.0)

Getting the following error when opening android studio :
3:01:59 PM Plugin Error: Android Tests Recorder threw an uncaught PluginException. Disable Plugin
3:01:59 PM PluginException: cannot create class "com.vpedak.testsrecorder.plugin.actions.ToolsTestsRecorderAction" [Plugin: com.vpedak.testsrecorder.plugin.id]
3:02:29 PM EmptyThrowable: Null child action in group Tools () of class class com.intellij.openapi.actionSystem.DefaultCompactActionGroup, id=vpedak.tools.tests.recorder

Spinners cause runtime exception

java.lang.RuntimeException: setOnItemClickListener cannot be used with a spinner.
at android.widget.Spinner.setOnItemClickListener(Spinner.java:559)
at com.vpedak.testsrecorder.core.AdapterViewProcessor.processView(AdapterViewProcessor.java:20)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:96)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.processView(ActivityProcessor.java:105)
at com.vpedak.testsrecorder.core.ActivityProcessor.access$100(ActivityProcessor.java:27)
at com.vpedak.testsrecorder.core.ActivityProcessor$1.run(ActivityProcessor.java:63)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

Test running failed: Instrumentation run failed due to 'java.lang.RuntimeException'

Hard coded path to the plugin link

Hello,
In this file :
com/vpedak/testsrecorder/plugin/actions/ToolsTestsRecorderAction.java

The path to the plugin file is hard coded, so it can't work on any other computer than yours.

Error description :

Error:Cannot convert URL 'C:/Users/vpedak/IdeaProjects/droidtestrec/AndroidTestsRecorder.jar' to a file.

NavigationMenu (/Drawer Layout) testing items

So the android.support.design.widget NavigationView is a sidebar you can pull out on Android devices and can inflate with a menu of options (to later add click interaction)

However testing this in espresso can be nightmare and was hoping your test recorder would help me out, to no effect.

The problem is. if you have a longish menu and record the test on a highish resolution emulator, you click the hamburger menu to open the sidebar (fine) then click say option 9 (visible on screen) and generate this skeleton test code:

onView(nthChildOf(withId(R.id.toolbar), 2)).perform(click());
onView(nthChildOf(withId(R.id.design_navigation_view), 9)).perform(click());

Now the problem exists if you later test this espresso skeleton on a smaller resolution emulator (where 9th child of the sidebar is just out of view) apparently these options are not in the hierarchy until scrolled too.(Great navigation support library google?!) But yeah the test fails...

So I don't know if this is an issue with the nthChild matcher you generate, or something you can forsee/fix, but just a heads up. Might have explained this bad but if you need any more clarification let me know.

Doesn't work on the latest Android Studio and gradle.

Hi,
I am using Android Studio v2.0-beta7 and gradle v2.0.0-beta7.

When I try to start recording tests, I get the following error:

Error running TestRecorderTemporary1458444695480: This version of Android Studio is incompatible with the Gradle Plugin used. Try disabling Instant Run (or updating either the IDE or the Gradle plugin to the latest version).

[UPDATE] I was able to get the test runner to work.

However, none of actions, button presses are being recorded.

Can you please help.

Thanks

PS: These are the logs generated:

03-20 09:37:47.461 18540-18540/com.firstcare.demo D/AndriodTestRecorder1458446701623: event=[16842,,view=R.id.btn_messaging_back,action=click,Click at Button with id R.id.btn_messaging_back]
03-20 09:37:57.510 18540-18540/com.firstcare.demo D/AndriodTestRecorder1458446701623: event=[10049,,view=R.id.btn_start_messaging,action=click,Click at Button with id R.id.btn_start_messaging]
03-20 09:37:59.125 18540-18540/com.firstcare.demo D/AndriodTestRecorder1458446701623: event=[1615,,view=R.id.btn_messaging_back,action=click,Click at Button with id R.id.btn_messaging_back]
03-20 09:37:59.164 1195-1557/? D/AudioFlinger: mixer(0xf44c0000) throttle end: throttle time(187)
03-20 09:37:59.658 18540-18540/com.firstcare.demo D/AndriodTestRecorder1458446701623: event=[533,,view=R.id.btn_start_open_chat,action=click,Click at Button with id R.id.btn_start_open_chat]

                                                                                      --------- beginning of system
03-20 09:37:59.658 1599-1882/system_process I/ActivityManager: START u0 {cmp=com.firstcare.demo/.sendbird.SendBirdChannelListActivity (has extras)} from uid 10059 on display 0
03-20 09:37:59.762 1195-1557/? D/AudioFlinger: mixer(0xf44c0000) throttle end: throttle time(1)
03-20 09:37:59.776 18540-18581/com.firstcare.demo W/EGL_emulation: eglSurfaceAttrib not implemented
03-20 09:37:59.776 18540-18581/com.firstcare.demo W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0x7fc442fffe40, error=EGL_SUCCESS
03-20 09:37:59.802 1195-1557/? D/AudioFlinger: mixer(0xf44c0000) throttle end: throttle time(11)
03-20 09:37:59.846 18540-18540/com.firstcare.demo D/123: view - android.widget.ImageButton{39a7b08 VFED..C.. ......ID 0,0-131,126 #7f0d0067 app:id/btn_close} listener - com.firstcare.demo.sendbird.SendBirdChannelListActivity$2@a7302a1
03-20 09:37:59.846 18540-18540/com.firstcare.demo D/123: view - android.widget.ImageButton{8e03fb4 VFED..C.. ......ID 949,0-1080,126 #7f0d0069 app:id/btn_settings} listener - com.firstcare.demo.sendbird.SendBirdChannelListActivity$3@41c27dd
03-20 09:37:59.880 1599-1620/system_process I/ActivityManager: Displayed com.firstcare.demo/.sendbird.SendBirdChannelListActivity: +211ms
03-20 09:37:59.943 18540-18581/com.firstcare.demo E/Surface: getSlotFromBufferLocked: unknown buffer: 0x7fc4397ce530
03-20 09:38:01.409 18540-18540/com.firstcare.demo W/ViewRootImpl: Cancelling event due to no window focus: MotionEvent { action=ACTION_CANCEL, actionButton=0, id[0]=0, x[0]=470.39063, y[0]=876.3867, toolType[0]=TOOL_TYPE_FINGER, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=0, eventTime=2755003, downTime=2753156, deviceId=0, source=0x1002 }
03-20 09:38:01.409 18540-18540/com.firstcare.demo W/ViewRootImpl: Cancelling event due to no window focus: MotionEvent { action=ACTION_CANCEL, actionButton=0, id[0]=0, x[0]=470.39063, y[0]=876.3867, toolType[0]=TOOL_TYPE_FINGER, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=0, eventTime=2755003, downTime=2753156, deviceId=0, source=0x1002 }
03-20 09:38:01.409 18540-18540/com.firstcare.demo W/ViewRootImpl: Cancelling event due to no window focus: MotionEvent { action=ACTION_CANCEL, actionButton=0, id[0]=0, x[0]=470.39063, y[0]=876.3867, toolType[0]=TOOL_TYPE_FINGER, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=0, eventTime=2755003, downTime=2753156, deviceId=0, source=0x1002 }
03-20 09:38:01.409 18540-18540/com.firstcare.demo W/ViewRootImpl: Cancelling event due to no window focus: MotionEvent { action=ACTION_CANCEL, actionButton=0, id[0]=0, x[0]=470.39063, y[0]=876.3867, toolType[0]=TOOL_TYPE_FINGER, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=0, eventTime=2755003, downTime=2753156, deviceId=0, source=0x1002 }
03-20 09:38:01.512 18540-18540/com.firstcare.demo D/AndriodTestRecorder1458446701623: event=[1854,,view=R.id.btn_close,action=click,Click at ImageButton with id R.id.btn_close]
03-20 09:38:01.610 18540-18581/com.firstcare.demo W/EGL_emulation: eglSurfaceAttrib not implemented
03-20 09:38:01.610 18540-18581/com.firstcare.demo W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0x7fc43867c340, error=EGL_SUCCESS
03-20 09:38:01.642 1195-1557/? D/AudioFlinger: mixer(0xf44c0000) throttle end: throttle time(11)
03-20 09:38:01.771 18540-18581/com.firstcare.demo E/Surface: getSlotFromBufferLocked: unknown buffer: 0x7fc4397cefb0
03-20 09:38:01.817 18540-18621/com.firstcare.demo D/AndriodTestRecorder1458446701623: event=[305,,espresso,action=pressback,Press on the back button]

EmptyThrowable error

EmptyThrowable: The APK file /myapp/build/outputs/apk/myapp-debug-androidTest-unaligned.apk does not exist on disk.

Given this issue combined with #25, I really think the plugin needs to move to a pre-built apk model (similar to robotium's android studio plugin). The existing reliance on Gradle is too flaky.

invalid path encoding

dependencies {
    // ...
    compile files('/Users/janusz/Library/Application%20Support/AndroidStudio1.4/AndroidTestsRecorder/lib/AndroidTestsRecorder.jar')
}

after replacing %20 with space it doesn't recognise the package and the plugin adds it again.

button to clear logs

would be nice to have a way of clearing the logs without stop/start which rebuilds the module

getInstrumentation() compiling error

Last week I reinstalled Android Studio, after that there are getInstrumentation() compiling errors with the generated code. This is because import static android.support.test.InstrumentationRegistry.*; is not declared in the source code. Could you add this line to the generated source code? Thanks!

ClassCastException with groovy class

It happens when I'm trying to record groovy class

2015-11-20 21:59:24,865 [ 428232]  ERROR - llij.ide.plugins.PluginManager - org.jetbrains.plugins.groovy.lang.psi.impl.GroovyFileImpl cannot be cast to com.intellij.psi.PsiJavaFile 
java.lang.ClassCastException: org.jetbrains.plugins.groovy.lang.psi.impl.GroovyFileImpl cannot be cast to com.intellij.psi.PsiJavaFile
    at com.vpedak.testsrecorder.plugin.actions.ToolsTestsRecorderAction.record(ToolsTestsRecorderAction.java:290)
    at com.vpedak.testsrecorder.plugin.actions.ToolsTestsRecorderAction.access$100(ToolsTestsRecorderAction.java:48)
    at com.vpedak.testsrecorder.plugin.actions.ToolsTestsRecorderAction$1.actionPerformed(ToolsTestsRecorderAction.java:104)
    at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2022)
    at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2346)
    at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402)
    at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
    at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:252)
    at java.awt.Component.processMouseEvent(Component.java:6525)
    at javax.swing.JComponent.processMouseEvent(JComponent.java:3324)
    at java.awt.Component.processEvent(Component.java:6290)
    at java.awt.Container.processEvent(Container.java:2234)
    at java.awt.Component.dispatchEventImpl(Component.java:4881)
    at java.awt.Container.dispatchEventImpl(Container.java:2292)
    at java.awt.Component.dispatchEvent(Component.java:4703)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4898)
    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4533)
    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4462)
    at java.awt.Container.dispatchEventImpl(Container.java:2278)
    at java.awt.Window.dispatchEventImpl(Window.java:2750)
    at java.awt.Component.dispatchEvent(Component.java:4703)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
    at java.awt.EventQueue.access$500(EventQueue.java:97)
    at java.awt.EventQueue$3.run(EventQueue.java:709)
    at java.awt.EventQueue$3.run(EventQueue.java:703)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86)
    at java.awt.EventQueue$4.run(EventQueue.java:731)
    at java.awt.EventQueue$4.run(EventQueue.java:729)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
    at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:734)
    at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:565)
    at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:382)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
2015-11-20 21:59:24,867 [ 428234]  ERROR - llij.ide.plugins.PluginManager - Android Studio 1.5  Build #AI-141.2422023 
2015-11-20 21:59:24,867 [ 428234]  ERROR - llij.ide.plugins.PluginManager - JDK: 1.8.0_60-ea 
2015-11-20 21:59:24,867 [ 428234]  ERROR - llij.ide.plugins.PluginManager - VM: Java HotSpot(TM) 64-Bit Server VM 

Android studio throws NoSuchMethodError

Hi I'm using Android Studio 2.1.1 on a Mac and I get this error as soon as when I hit the record button.

java.io.File.toPath()Ljava/nio/file/Path;
java.lang.NoSuchMethodError: java.io.File.toPath()Ljava/nio/file/Path;
at com.vpedak.testsrecorder.plugin.actions.ToolsTestsRecorderAction.record(ToolsTestsRecorderAction.java:410)
at com.vpedak.testsrecorder.plugin.actions.ToolsTestsRecorderAction.access$100(ToolsTestsRecorderAction.java:64)
at com.vpedak.testsrecorder.plugin.actions.ToolsTestsRecorderAction$1.actionPerformed(ToolsTestsRecorderAction.java:123)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2028)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2351)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)
at java.awt.Component.processMouseEvent(Component.java:6414)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3275)
at java.awt.Component.processEvent(Component.java:6179)
at java.awt.Container.processEvent(Container.java:2084)
at java.awt.Component.dispatchEventImpl(Component.java:4776)
at java.awt.Container.dispatchEventImpl(Container.java:2142)
at java.awt.Component.dispatchEvent(Component.java:4604)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4618)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4279)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4209)
at java.awt.Container.dispatchEventImpl(Container.java:2128)
at java.awt.Window.dispatchEventImpl(Window.java:2492)
at java.awt.Component.dispatchEvent(Component.java:4604)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:717)
at java.awt.EventQueue.access$400(EventQueue.java:82)
at java.awt.EventQueue$2.run(EventQueue.java:676)
at java.awt.EventQueue$2.run(EventQueue.java:674)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:86)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:97)
at java.awt.EventQueue$3.run(EventQueue.java:690)
at java.awt.EventQueue$3.run(EventQueue.java:688)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:86)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:687)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:866)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:650)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:381)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Deletes all dependencies after recording

All the dependencies in my build.gradle file have been deleted using the recording plugin. :(

I thought #19 was fixed? Is it not published yet to the Android Studio plugins directory?

Clicking record deletes dependencies in my app's build.gradle

I already have espresso setup and working in my AS2 project (using android gradle 2.0.0).

If I open up the recorder, select my app target and main activity, pressing record removes dependencies from my build.gradle and the app then fails to compile.

NPE on Drawer open guesture

Start recording test and try to open drawer:

Test running started
java.lang.NullPointerException: Attempt to invoke virtual method 'float android.view.MotionEvent.getY()' on a null object reference
at com.vpedak.testsrecorder.core.ActivityProcessor$GestureDetectorRunnable$1.onFling(ActivityProcessor.java:192)
at android.view.GestureDetector.onTouchEvent(GestureDetector.java:610)
at com.vpedak.testsrecorder.core.ActivityProcessor$1.onTouch(ActivityProcessor.java:141)
at android.view.View.dispatchTouchEvent(View.java:8470)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2401)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2092)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2407)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2106)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2407)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2106)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2407)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2106)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2407)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2106)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2407)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2106)
at com.android.internal.policy.impl.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:2369)
at com.android.internal.policy.impl.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1719)
at android.app.Activity.dispatchTouchEvent(Activity.java:2752)
at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:60)
at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:60)
at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:2330)
at android.view.View.dispatchPointerEvent(View.java:8671)
at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4193)
at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4059)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3604)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3657)
at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:3623)
at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:3740)
at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:3631)
at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:3797)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3604)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3657)
at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:3623)
at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:3631)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3604)
at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:5912)
at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:5851)
at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:5822)
at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:6002)
at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:192)
at android.view.InputEventReceiver.nativeConsumeBatchedInputEvents(Native Method)
at android.view.InputEventReceiver.consumeBatchedInputEvents(InputEventReceiver.java:183)
at android.view.ViewRootImpl.doConsumeBatchedInput(ViewRootImpl.java:5973)
at android.view.ViewRootImpl$ConsumeBatchedInputRunnable.run(ViewRootImpl.java:6025)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:767)
at android.view.Choreographer.doCallbacks(Choreographer.java:580)
at android.view.Choreographer.doFrame(Choreographer.java:548)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:753)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5343)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:905)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:700)

Test running failed: Instrumentation run failed due to 'java.lang.NullPointerException'

help help me!!!

AndroidDebugBridge.init() has already been called.
java.lang.IllegalStateException: AndroidDebugBridge.init() has already been called.
at com.android.ddmlib.AndroidDebugBridge.init(AndroidDebugBridge.java:210)
at com.android.tools.idea.ddms.adb.AdbService$CreateBridgeTask.call(AdbService.java:175)
at com.android.tools.idea.ddms.adb.AdbService$CreateBridgeTask.call(AdbService.java:158)
at com.intellij.openapi.application.impl.ApplicationImpl$9.call(ApplicationImpl.java:394)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
I don‘t know why?

Problems with multiple same IDs

I have layout that is using databinding and has multiple same components, that include EditText with same id (R.id.edit_value).
When recording the test, this ID is used in ViewMatcher, but then the test fails, because there are multiple view with same id in window.
Shouldn't recorder check, if the recorded ID is unique inside the window and if not, at least throw some warning? Best way would be switching to identifing by multiple IDs from parents (my current workaround)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.