Forum Discussion

iou1006's avatar
iou1006
Occasional Contributor
9 years ago
Solved

When I run the groovy script the second time, error message displayed as "NullPointerException"

My Ready!API version is 1.50.  

 

I import an existing project. when I first run the script, it passed with no exception. But the second time error message displayed as following. 

 

Mon Nov 16 15:26:07 CST 2015:ERROR:java.lang.NullPointerException
java.lang.NullPointerException
at com.eviware.soapui.support.scripting.groovy.SoapUIGroovyScriptEngine.setVariable(SoapUIGroovyScriptEngine.java:147)
at com.eviware.soapui.impl.wsdl.teststeps.WsdlGroovyScriptTestStep.run(WsdlGroovyScriptTestStep.java:149)
at com.eviware.soapui.impl.wsdl.panels.teststeps.GroovyScriptStepDesktopPanel$RunAction$1.run(GroovyScriptStepDesktopPanel.java:263)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)

7 Replies

  • nmrao's avatar
    nmrao
    Champion Level 3

    Please post the script and attach error log.

    • iou1006's avatar
      iou1006
      Occasional Contributor

      The Error log is already in the description. the script is a blank one. I even commented all the code and the same error still there

    • iou1006's avatar
      iou1006
      Occasional Contributor

      Forget this error log

       

      Tue Nov 17 10:18:51 CST 2015:ERROR:cannot get error line number!
      Tue Nov 17 10:18:51 CST 2015:ERROR:java.lang.IllegalStateException: No match found
      java.lang.IllegalStateException: No match found
      at java.util.regex.Matcher.group(Unknown Source)
      at com.eviware.soapui.support.GroovyUtils.extractErrorLineNumber(GroovyUtils.java:132)
      at com.eviware.soapui.impl.wsdl.teststeps.WsdlGroovyScriptTestStep.run(WsdlGroovyScriptTestStep.java:177)
      at com.eviware.soapui.impl.wsdl.panels.teststeps.GroovyScriptStepDesktopPanel$RunAction$1.run(GroovyScriptStepDesktopPanel.java:263)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)

    • iou1006's avatar
      iou1006
      Occasional Contributor

      I just tried to create a new test case with "Run TestCase" step, and also invoke a new test case with only a blank Groovy script. When I try to run the case the second time, the same error displayed