[MGNLTEST-279] Build of test-fwk triggers both cucumber-ui-tests and "normal" ui-tests Created: 27/Jun/22  Updated: 15/Jul/22  Resolved: 07/Jul/22

Status: Closed
Project: Magnolia Test Framework
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Neutral
Reporter: Christoph Meier Assignee: Unassigned
Resolution: Won't Do Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: 1d 3.5h
Original Estimate: Not Specified

Issue Links:
relation
is related to MGNLTEST-280 (Consider) proper cucumber scenario t... Closed
Template:
Acceptance criteria:
Empty
Task DoR:
Empty
Epic Link: cucumber-and-selenide-support-by-test-fwk

 Description   

While working on MGNLTEST-268 ...
... changes on the pom, adding depenencies used by cucumber ...
cucumber-ui-tests are triggered ...
BUT "normal" UI tests are not triggered anymore.

Actually IntelliJ is also does not launch the "normal" ui-tests anymore.

List of some of the "normal UI tests" in the test-fwk:

  • it.info.magnolia.test.selenide.pageobjects.UiTestSelenideOnly
  • all tests in package it.info.magnolia.test.selenium

How it should work

  1. junit5 UI-tests still can be launched via IDE  
  2. cucumber ui-tests also can be launched via IDE via feature-file
  3. running mvn clean install -Pintegration-tests still works - launching the int tests
  4. cucumber INT/ui-tests alsco can be launched via mvn
    e.g. via mvn clean install -Pcucumber-integration-tests
  5.  (3) and (4) can be run both together in one "build"

 

P.S. (2) seems to work - but it is not exectuting code from it.info.magnolia.test.cucumber.ui.CucumberTests (which e.g. setups the webdriver)

 

The above "how it should work" adds a new profile. This means that we also need to adapt a jenkins-template.

Furthermore, ideally we use latest cucumber-libraries (see POM, cucumber-BOM, currently it is 7.0.0)
This also means that the java-class should not use @RunWith(Cucumber.class), @CucumberOptions),
But should use @Suite, see CucumberTests

 

Developer notes

See PR https://git.magnolia-cms.com/projects/PLATFORM/repos/test-framework/pull-requests/189/overview for changes on the pom



 Comments   
Comment by Christoph Meier [ 07/Jul/22 ]

As for now - this won't do it.

I did a dummy-project where it works perfect. 

  • To run junit5-tests run -> `mvn -Pintegration-tests`
  • To run cucumber-tests run -> `mvn -Pcucumber-tests`

With the test-packages 

  • it.info.magnolia.test
  • cute.info.magnolia.test

Unfortunately, in test-fwk I was not able to achive such setup - even though I did the same way.
But most likely it is not really necessary to run these 2 types of tests within same module.

Generated at Mon Feb 12 07:47:18 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.