big-automation / automation-engine

Standalone Selenium ATE without OSGI framework
Apache License 2.0
0 stars 0 forks source link

in multi browser support feature, add firefox profile selection feature #18

Open peidong-hu opened 9 years ago

peidong-hu commented 9 years ago

when starting firefox browser, system should be able to select which firefox profile to start with.

The use case is, for example, set the profile to accept location share in a google maps application, the solution is here, http://stackoverflow.com/questions/16292634/always-allow-geolocation-in-firefox-using-selenium and http://techyworks.blogspot.ca/2013/10/change-geolocation-using-selenium.html

Jun-Yang commented 9 years ago

新下载代码编译遇到的问题: Exception in thread "main" java.lang.NullPointerException at org.bigtester.ate.model.data.TestDatabaseInitializer.setSingleInitXmlFile(TestDatabaseInitializer.java:206) at org.bigtester.ate.model.data.TestDatabaseInitializer$$FastClassBySpringCGLIB$$9a1ac46b.invoke() at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204) at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:708) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) at org.springframework.aop.aspectj.AspectJAfterThrowingAdvice.invoke(AspectJAfterThrowingAdvice.java:58) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:92) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:644) at org.bigtester.ate.model.data.TestDatabaseInitializer$$EnhancerBySpringCGLIB$$2bfed6fa.setSingleInitXmlFile() at org.bigtester.ate.TestProjectRunner.runTest(TestProjectRunner.java:102) at org.bigtester.ate.TestProjectRunner.main(TestProjectRunner.java:67) Suppressed: java.lang.Exception: Error Already System Level Pointcut. at org.bigtester.ate.systemlogger.GenericSystemLogger.setAlreadySysPointCut(GenericSystemLogger.java:64) at org.bigtester.ate.systemlogger.GenericSystemLogger.afterThrowingAdvice(GenericSystemLogger.java:78) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:621) at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:603) at org.springframework.aop.aspectj.AspectJAfterThrowingAdvice.invoke(AspectJAfterThrowingAdvice.java:62) ... 7 more

2015-01-04 11:45 GMT-05:00 peidong-hu notifications@github.com:

when starting firefox browser, system should be able to select which firefox profile to start with.

The use case is, for example, set the profile to accept location share in a google maps application

— Reply to this email directly or view it on GitHub https://github.com/bigtester/automation-test-engine/issues/18.

peidong-hu commented 9 years ago

Need to add a parameter in ate:TestProject tag as shown below, I have re-strucutured the data management structure. data.xml is only initialized the project-wide global testing data.

The test case specific data has been moved to pageObjects folder.

See the example in https://github.com/bigtester/automation-test-engine/tree/master/org.bigtester.ate.core/testproject2 or https://github.com/peidong-hu/dentisteasy/tree/master/dentistSmokeTest

peidong

<ate:TestProject id="testproject" stepThinkTime="6" globalInitXmlFile="dentistSmokeTest/data.xml">

``` ``` ``` ``` On 01/05/2015 10:47 AM, Jun Yang wrote: > 新下载代码编译遇到的问题: > Exception in thread "main" java.lang.NullPointerException > at > org.bigtester.ate.model.data.TestDatabaseInitializer.setSingleInitXmlFile(TestDatabaseInitializer.java:206) > > at > org.bigtester.ate.model.data.TestDatabaseInitializer$$FastClassBySpringCGLIB$$9a1ac46b.invoke() > > at > org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204) > at > org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:708) > > at > org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) > > at > org.springframework.aop.aspectj.AspectJAfterThrowingAdvice.invoke(AspectJAfterThrowingAdvice.java:58) > > at > org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) > > at > org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:92) > > at > org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) > > at > org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:644) > > at > org.bigtester.ate.model.data.TestDatabaseInitializer$$EnhancerBySpringCGLIB$$2bfed6fa.setSingleInitXmlFile() > > at > org.bigtester.ate.TestProjectRunner.runTest(TestProjectRunner.java:102) > at org.bigtester.ate.TestProjectRunner.main(TestProjectRunner.java:67) > Suppressed: java.lang.Exception: Error Already System Level Pointcut. > at > org.bigtester.ate.systemlogger.GenericSystemLogger.setAlreadySysPointCut(GenericSystemLogger.java:64) > > at > org.bigtester.ate.systemlogger.GenericSystemLogger.afterThrowingAdvice(GenericSystemLogger.java:78) > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > > at java.lang.reflect.Method.invoke(Method.java:606) > at > org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:621) > > at > org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:603) > > at > org.springframework.aop.aspectj.AspectJAfterThrowingAdvice.invoke(AspectJAfterThrowingAdvice.java:62) > > ... 7 more > > 2015-01-04 11:45 GMT-05:00 peidong-hu notifications@github.com: > > > when starting firefox browser, system should be able to select which > > firefox profile to start with. > > > > The use case is, for example, set the profile to accept location > > share in > > a google maps application > > > > — > > Reply to this email directly or view it on GitHub > > https://github.com/bigtester/automation-test-engine/issues/18. > > — > Reply to this email directly or view it on GitHub > https://github.com/bigtester/automation-test-engine/issues/18#issuecomment-68726259.