We are currently using a self-made testing framework/tool, to test services of an client-server application. The framework currently works with own implemented JUnit like
assert methods and reports.
The frameworks works like this:
- Test cases are defined as CSV files
- Each line of a CSV file contains a test step
- Each test step has a unique name and parameters
Create Product;name;price;count ;PlayStation 3;300;10 Validate Product;name;price;count ;PlayStation 3;300;10
Each test step is defined as a Java class
The framework parse the CSV file, find the test steps, create a test case to run it and create a report.
What I want
I want to execute the test cases and report the results by native JUnit.
What is the question?
How can I generate JUnit compatible test cases by CSV files and test steps?
Because of reasons, we are not able to switch to a completely new framework like Cucumber or anything similar. The goal is to have the JUnit
assert methods, because they are more reliable than self-made and to have the JUnit reports, that tools like Bamboo, Jenkins and other are able to get accurate reports in the compatible JUnit format.
I am currently try different things to implement JUnit in the framework, but haven't found a solution yet. I hope I am able to solve this issue with your support.
If you know any other framework or library to solve this issue, please also let me know.
If you have any questions to understand the question or context better, let me know.
Thanks for your support.
I tried to create a custom JUnit runner. The issue is that a JUnit Runner expects a test class and in this case a test class doesn't exists. I looked into projects like Cucumber to see how they implemented the JUnit Runner but wasn't able to figure out how it's working yet.