jeudi 23 janvier 2020

Run specific tests based on parameters within test cases with 'mvn test -Dtest' command

I am attempting to run specific tests within our regression suite. I am fairly new to our framework so still getting my hands dirty in the code, but we are trying to set up our pipeline to run tests in a more frequent and more customized way.

i can run folders fine with mvn -Dtest=path.to.folder.** command but i cant figure the way to run tests within that folder that have a specific tag. we have multiple variables within a @TestHeaderInfo tag that i am trying to call. one specific one within @TestHeaderInfo is groups="Regression". that would be the most optimal tag to be able to grab.

i have been looking for a while and cannot seem to find the maven command to grab tags, or i dont have the proper code in the pom file in order to run what i have already tried.

I was also able to run specific methods within the folder but those methods are specific to one test and to add them across our suite would be time consuming/bad practice so i passed on that.

any ideas or guidance would be appreciated.

thanks

Aucun commentaire:

Enregistrer un commentaire