|
View:
New views
1 Messages
—
Rating Filter:
Alert me
|
|
|
[webtest][JIRA] Created: (WT-531) Using mobile proxy user agent fails with Illegal browser version: >Netscape2.0 when doing verifyLinkedContentUsing mobile proxy user agent fails with Illegal browser version: >Netscape2.0 when doing verifyLinkedContent
------------------------------------------------------------------------------------------------------------- Key: WT-531 URL: http://webtest-community.canoo.com/jira/browse/WT-531 Project: WebTest Type: Bug Versions: Future work Environment: canoo 3.1-SNAPSHOT, groovy 1.6.3, testing via mvn on mac Reporter: Ian Homer Mobile operators sometimes proxy mobile web traffic through a proxy - one of these proxies has a user-agent of "Mozilla/5.0 (X11; U; Linux i686; en-US; rv%3a1.8.0.7) Gecko/20060909 Firefox/1.5.0.7 MG(Novarra-Vision/7.3)". If we do a test script for a mobile device connecting through this proxy then canoo errors on verifyLinkedContent with the stack trace below --TEST SCRIPT : START-- package com.bemoko.webtest.canoo import com.canoo.webtest.WebtestCase /** * Test how canoo deals with a Novarra proxy header */ class NovarraUserAgentTest extends WebtestCase { void test() { webtest("NovarraUserAgentTest") { config(host:"localhost",port:80,haltonfailure:false) { header name:"User-Agent",value:"Mozilla/5.0 (X11; U; Linux i686; en-US; rv%3a1.8.0.7) Gecko/20060909 Firefox/1.5.0.7 MG(Novarra-Vision/7.3)" header name:"x-Device-User-Agent",value:"SonyEricssonV600i/R2K Browser/SEMC-Browser/4.2 Profile/MIDP-2.0 Configuration/CLDC-1.1" } invoke "/bemoko/i" verifyTitle "bemoko - creating mobile websites" verifyLinkedContent xpath:"/html/head/link[@rel='stylesheet']/@href", accept:"text/css" } } } --TEST SCRIPT END-- --STACKTRACE START-- : Unexpected exception caught: java.lang.IllegalArgumentException at com.canoo.webtest.steps.StepUtil.handleException(StepUtil.java:120) at com.canoo.webtest.steps.Step.handleException(Step.java:387) at com.canoo.webtest.steps.Step.execute(Step.java:118) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288) at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at com.canoo.webtest.ant.TestStepSequence.executeSteps(TestStepSequence.java:43) at com.canoo.webtest.ant.TestStepSequence.doExecute(TestStepSequence.java:31) at com.canoo.webtest.steps.Step.execute(Step.java:103) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at com.canoo.webtest.ant.WebtestTask.executeSteps(WebtestTask.java:236) at com.canoo.webtest.ant.WebtestTask.execute(WebtestTask.java:208) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at groovy.util.AntBuilder.nodeCompleted(AntBuilder.java:204) at groovy.util.BuilderSupport.doInvokeMethod(BuilderSupport.java:147) at groovy.util.AntBuilder.doInvokeMethod(AntBuilder.java:154) at com.canoo.webtest.groovy.WebTestBuilder.doInvokeMethod(WebTestBuilder.java:54) at groovy.util.BuilderSupport.invokeMethod(BuilderSupport.java:64) at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:45) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:40) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:117) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:129) at com.canoo.webtest.WebtestCase.webtest(WebtestCase.groovy:104) at com.canoo.webtest.WebtestCase$webtest.callCurrent(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:44) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:143) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:155) at com.bemoko.webtest.canoo.NovarraUserAgentTest.test(NovarraUserAgentTest.groovy:13) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at junit.framework.TestCase.runTest(TestCase.java:168) at junit.framework.TestCase.runBare(TestCase.java:134) at junit.framework.TestResult$1.protect(TestResult.java:110) at junit.framework.TestResult.runProtected(TestResult.java:128) at junit.framework.TestResult.run(TestResult.java:113) at junit.framework.TestCase.run(TestCase.java:124) at junit.framework.TestSuite.runTest(TestSuite.java:232) at junit.framework.TestSuite.run(TestSuite.java:227) at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:81) at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127) at org.apache.maven.surefire.Surefire.run(Surefire.java:177) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:345) at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1009) Caused by: java.lang.IllegalArgumentException: Illegal browser version: >Netscape2.0 at com.canoo.webtest.engine.Configuration.setupBrowserVersion(Configuration.java:708) at com.canoo.webtest.engine.Configuration.createWebClient(Configuration.java:629) at com.canoo.webtest.extension.VerifyLinkedContent.setupWebClient(VerifyLinkedContent.java:102) at com.canoo.webtest.extension.VerifyLinkedContent.verifyLinksOnPage(VerifyLinkedContent.java:110) at com.canoo.webtest.extension.VerifyLinkedContent.doExecute(VerifyLinkedContent.java:93) at com.canoo.webtest.steps.Step.execute(Step.java:103) ... 61 more --- Nested Exception --- java.lang.IllegalArgumentException: Illegal browser version: >Netscape2.0 at com.canoo.webtest.engine.Configuration.setupBrowserVersion(Configuration.java:708) at com.canoo.webtest.engine.Configuration.createWebClient(Configuration.java:629) at com.canoo.webtest.extension.VerifyLinkedContent.setupWebClient(VerifyLinkedContent.java:102) at com.canoo.webtest.extension.VerifyLinkedContent.verifyLinksOnPage(VerifyLinkedContent.java:110) at com.canoo.webtest.extension.VerifyLinkedContent.doExecute(VerifyLinkedContent.java:93) at com.canoo.webtest.steps.Step.execute(Step.java:103) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288) at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at com.canoo.webtest.ant.TestStepSequence.executeSteps(TestStepSequence.java:43) at com.canoo.webtest.ant.TestStepSequence.doExecute(TestStepSequence.java:31) at com.canoo.webtest.steps.Step.execute(Step.java:103) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at com.canoo.webtest.ant.WebtestTask.executeSteps(WebtestTask.java:236) at com.canoo.webtest.ant.WebtestTask.execute(WebtestTask.java:208) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at groovy.util.AntBuilder.nodeCompleted(AntBuilder.java:204) at groovy.util.BuilderSupport.doInvokeMethod(BuilderSupport.java:147) at groovy.util.AntBuilder.doInvokeMethod(AntBuilder.java:154) at com.canoo.webtest.groovy.WebTestBuilder.doInvokeMethod(WebTestBuilder.java:54) at groovy.util.BuilderSupport.invokeMethod(BuilderSupport.java:64) at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:45) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:40) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:117) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:129) at com.canoo.webtest.WebtestCase.webtest(WebtestCase.groovy:104) at com.canoo.webtest.WebtestCase$webtest.callCurrent(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:44) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:143) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:155) at com.bemoko.webtest.canoo.NovarraUserAgentTest.test(NovarraUserAgentTest.groovy:13) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at junit.framework.TestCase.runTest(TestCase.java:168) at junit.framework.TestCase.runBare(TestCase.java:134) at junit.framework.TestResult$1.protect(TestResult.java:110) at junit.framework.TestResult.runProtected(TestResult.java:128) at junit.framework.TestResult.run(TestResult.java:113) at junit.framework.TestCase.run(TestCase.java:124) at junit.framework.TestSuite.runTest(TestSuite.java:232) at junit.framework.TestSuite.run(TestSuite.java:227) at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:81) at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127) at org.apache.maven.surefire.Surefire.run(Surefire.java:177) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:345) at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1009) --STACKTRACE END-- -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://webtest-community.canoo.com/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira _______________________________________________ WebTest mailing list WebTest@... http://lists.canoo.com/mailman/listinfo/webtest |
| Free embeddable forum powered by Nabble | Forum Help |