title: NoSuchMethodError when executing a recorded test in IBM MobileFirst Test Workbench
body: <p>Unable to play recorded scripts on an Galaxy S5 with Android 5.0.2. </p>
  
  <p>NoSuchMethodError is thrown when executing a previously recorded test, in IBM MobileFirst Test Workbench. </p>
  
  <p>The same test plays out just fine on other versions of Android.</p>
  
  <hr>
  
  <p>Following the steps described in 
  <a href="https://developer.ibm.com/mobilefirstplatform/documentation/getting-started-6-3/advanced-topics/testing-mobilefirst-mobile-applications-mobile-test-workbench/" rel="nofollow noreferrer">https://developer.ibm.com/mobilefirstplatform/documentation/getting-started-6-3/advanced-topics/testing-mobilefirst-mobile-applications-mobile-test-workbench/</a>
  I have created my own MobileFirst project and slightly changed the index.html to:</p>
  
  <pre><code>&lt;!DOCTYPE HTML&gt;
  &lt;html&gt;
          &lt;head&gt;
              &lt;meta charset="UTF-8"&gt;
              &lt;title&gt;hw&lt;/title&gt;
              &lt;meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=0"&gt;
              &lt;!--
                  &lt;link rel="shortcut icon" href="images/favicon.png"&gt;
                  &lt;link rel="apple-touch-icon" href="images/apple-touch-icon.png"&gt; 
              --&gt;
              &lt;link rel="stylesheet" href="css/main.css"&gt;
              &lt;script&gt;window.$ = window.jQuery = WLJQ;&lt;/script&gt;
              &lt;script&gt;
                    function count_rabbits() {
                      for(var i=1; i&lt;=3; i++) {
                        alert("Rabbit "+i+" out of the hat!");
                    }
                }
              &lt;/script&gt;
              &lt;script src="js/tracekit.js" type="text/javascript"&gt;&lt;/script&gt;
              &lt;script src="js/MQA.js" type="text/javascript"&gt;&lt;/script&gt;
          &lt;/head&gt;
          &lt;body style="display: none;"&gt;
              &lt;!--application UI goes here--&gt;
              Hello MobileFirst
              &lt;script src="js/initOptions.js"&gt;&lt;/script&gt;
              &lt;script src="js/main.js"&gt;&lt;/script&gt;
              &lt;script src="js/messages.js"&gt;&lt;/script&gt;
  
    &lt;h2&gt;Press the button to start&lt;/h2&gt;  
  
      &lt;input type="button" onclick="count_rabbits()" value="Count rabbits!"/&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  
  
  
  
          &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>I built the application and deployed it on a Galaxy S5 with Android 5.0.2.
  The application works as expected.</p>
  
  <p>Then I create a Test Workbench project.
  Using the IBM Rational Test Workbench client from my phone, I upload my application and I record myself opening it, tapping OK three times and then tapping back, then stop the recording and put it in a test.</p>
  
  <p>The test shows up, I can save it and I can launch it.</p>
  
  <p>Here where it goes offscript. 
  <a href="https://i.stack.imgur.com/D72Y6.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/D72Y6.jpg" alt="enter image description here"></a></p>
  
  <p>It runs for a little and it fails with a:</p>
  
  <pre><code>An uncaught exception has been thrown in thread Thread[main,5,main]: NoSuchMethodError: No direct method &lt;init&gt;(Lcom/ibm/rational/test/mobile/android/runtime/webkit/WebViewClientWrapper_rtwrenamed;Ljava/net/HttpURLConnection;Ljava/net/URL;[Ljava/lang/String;Ljava/lang/String;)V in class Lcom/ibm/rational/test/mobile/android/runtime/webkit/WebViewClientWrapper$1; or its super classes (declaration of 'com.ibm.rational.test.mobile.android.runtime.webkit.WebViewClientWrapper$1' appears in /data/app/com.myhw-1/base.apk)
      at com.ibm.rational.test.mobile.android.runtime.webkit.WebViewClientWrapper_rtwrenamed.loadRemoteJavascriptsSource(WebViewClientWrapper.java:290)
      at com.ibm.rational.test.mobile.android.runtime.webkit.WebViewClientWrapper_rtwrenamed.loadJavaScriptResource(WebViewClientWrapper.java:242)
      at com.ibm.rational.test.mobile.android.runtime.webkit.WebViewClientWrapper_rtwrenamed.loadAndInject(WebViewClientWrapper.java:205)
      at com.ibm.rational.test.mobile.android.runtime.playback.webkit.RMoTWebDriver$1.run(RMoTWebDriver.java:241)
      at android.os.Handler.handleCallback(Handler.java:739)
      at android.os.Handler.dispatchMessage(Handler.java:95)
      at android.os.Looper.loop(Looper.java:145)
      at android.app.ActivityThread.main(ActivityThread.java:6066)
      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:1399)
      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/WT5sg.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/WT5sg.jpg" alt="The error screen"></a></p>
  
  <p>What am I doing wrong?</p>
  
  <p>Windows 7 64 bit with jdk 1.8.0_77</p>
  
  <pre><code>C:\&gt;java -version
  java version "1.8.0_77"
  Java(TM) SE Runtime Environment (build 1.8.0_77-b03)
  Java HotSpot(TM) 64-Bit Server VM (build 25.77-b03, mixed mode)
  
  C:\&gt;javac -version
  javac 1.8.0_77
  </code></pre>
  
  <p>Luna with:</p>
  
  <pre><code>Android DDMS 23.0.7.2120684
  Android Development Tools   23.0.7.2120684  
  Android Hierarchy Viewer    23.0.7.2120684  
  Android Native Development Tools    23.0.7.2120684
  Android Traceview   23.0.7.2120684  
  Eclipse IDE for Java Developers 4.4.2.20150219-0708 epp.package.java    null
  IBM Dojo Mobile Tools   7.1.0.00-20160321-2138
  IBM jQuery Mobile Tools 7.1.0.00-20160321-2138
  IBM MobileFirst Platform Studio 7.1.0.00-20160321-2138
  IBM MobileFirst Platform Test Workbench 8.7.0.v20160112_2203  
  Tracer for OpenGL ES    23.0.7.2120684
  </code></pre>