Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting Tests are skipped When using Base Class #19

Open
MHamza-Y opened this issue Sep 25, 2020 · 0 comments
Open

Getting Tests are skipped When using Base Class #19

MHamza-Y opened this issue Sep 25, 2020 · 0 comments

Comments

@MHamza-Y
Copy link

Hi I am editing this example to create and run test with screenplay pattern. Currently I am trying to use a base class to manage Test data for my tests. Base Test class goes as follows,

public class BaseTest {
    public TestParams testParams;


    public BaseTest(Map<String,String> testData) {

        testParams = TestParams.haveValues(testData);
    }

    protected Actor james = Actor.named("James");
    @Managed
    protected WebDriver driver;

    @Before
    public void jamesCanBrowseTheWeb() {
        james.can(BrowseTheWeb.with(driver));
    }

    @TestData
    public Collection<Object[]> getTestData() {
        return DataProvider.getSheet("testdata/ExcelInputData.xlsx",this.getClass().getSimpleName());
    }
}

And my test class is,

public class CloneViewTest extends BaseTest {
    public CloneViewTest(Map<String,String> testData) {
        super(testData);
    }

    @Test
    public void should_be_able_to_clone_views() {
        james.attemptsTo(Open.browserOn().the(Column_dictionaryPage.class));

    }
}

But when I try to run this test I get
[INFO] Tests are skipped.
In the console log. It's my first try to use Serenity with screenplay pattern and i am not very familiar with it. I apologize in advance if it is something stupid.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant