Uploaded image for project: 'PUBLIC - Liferay Faces'
  1. PUBLIC - Liferay Faces
  2. FACES-3010

Liferay Faces integration tests no longer set a default browser

    Details

      Description

      When running integration tests, no default browser is specified, so one must be specified by the developer.

      Steps to reproduce:

      1. Run the integration tests without specifying a browser
         mvn verify -P selenium
        

      If the bug still exists, the following error message will appear:

      Running com.liferay.faces.test.showcase.selectmanylistbox.SelectManyListboxDataModelTester
      Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0 sec <<< FAILURE! - in com.liferay.faces.test.showcase.selectmanylistbox.SelectManyListboxDataModelTester
      runSelectManyListboxDataModelTest(com.liferay.faces.test.showcase.selectmanylistbox.SelectManyListboxDataModelTester)  Time elapsed: 0 sec  <<< ERROR!
      java.lang.NoClassDefFoundError: org/openqa/selenium/phantomjs/PhantomJSDriver
              at com.liferay.faces.test.selenium.Browser.<init>(Browser.java:107)
              at com.liferay.faces.test.selenium.Browser.getInstance(Browser.java:130)
              at com.liferay.faces.test.showcase.select.SelectManyTester.runSelectManyDataModelTest(SelectManyTester.java:89)
              at com.liferay.faces.test.showcase.selectmanylistbox.SelectManyListboxDataModelTester.runSelectManyListboxDataModelTest(SelectManyListboxDataModelTester.java:31)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:498)
              at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
              at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
              at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
              at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
              at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
              at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
              at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
              at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
              at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
              at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
              at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
              at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
              at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
              at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
              at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
              at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:367)
              at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:274)
              at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:238)
              at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:161)
              at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:290)
              at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:242)
              at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:121)
      

      If the bug is fixed, the tests will run normally with the default browser.

      In order to fix this bug, the dependencies and properties of the default browser should be moved to the selenium profile instead (since <activeByDefault>true</activeByDefault> only works when no other dependencies are specified).

      The default browser should always be phantomjs except in the TCK where it should be htmlunit.

      Finally as a related task, any properties in the activeByDefault liferay profile should be moved into the selenium profile as well.

        Attachments

          Activity

            People

            Assignee:
            neil.griffin Neil Griffin
            Reporter:
            kyle.stiemann Kyle Stiemann (Inactive)
            Participants of an Issue:
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Packages

                Version Package
                alloy-2.0.1
                bridge-impl-2.1.0
                metal-1.0.0
                bridge-impl-3.1.0
                bridge-impl-4.1.0
                showcase-2.0.1
                showcase-3.0.1
                alloy-3.0.1