-
Notifications
You must be signed in to change notification settings - Fork 7
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
Prepare testing with profiles #789
Conversation
This pull request creates all tests dynamically based on Cypress environment variable "selection". Within test code, this variable can be read with the expression Cypress.env('selection'). Cypress shows errors for spec files that do not have tests. For this reason, I create a dummy test. The name of the dummy test shows the value of Cypress.env('selection') that is the reason for not creating the tests. The environment variable is set in cypress.env.json. This is better then doing it on the command line, because the command lines appear as scripts in package.json. There are already many scripts for the different ways of testing. If we would make a script for every combination of a test approach and a test selection, the number of scripts would explode. In GitHub Actions we have a list of all test selections we want to test. This is an array in which each element is a choice for Cypress.env('selection'). Using the GitHub matrix syntax, a job is started for each option. Each option is executed. Having options to select tests only makes sense if we apply different Spring profiles of the backend for each option. This will be configured by writing frank-runner/specials/ladybug/build.properties. This part is not yet implemented because we do not know what Spring profiles to test with. |
@jacodg je hebt me net uitgelegd welke test met verschillende Spring profielen we nodig hebben. Ik maak deze PR af zodat ook het backend stuk daarvan gedaan wordt. Ik wou nog even uitstellen dat we nog iets te doen hebben voor handmatig testen. Als je handmatig wilt testen, dan moet je met de hand frank-runner/specials/ladybug/build.properties schrijven inclusief de selectie van een Spring profiel. Daarna moet je daar restart.bat of restart.sh starten. Pas als de backend dan draait, dan kan je de frontend testen waarbij je op moet letten dat cypress.env.json goed is. Dat zijn te veel handelingen om aan te denken. |
Ik denk dat het handig is om dat in de pom.xml van ladybug-backend te maken, zodat je met één enkel Maven commando de test van je keuze kunt doen. Die test logica zou denk ik wel gebruik kunnen maken van de tooling van de frank-runner. Maar niet voor nu dus. |
Ik denk dat het zo goed is. De test heeft op vier manieren gedraaid:
|
Superseded by #803. |
No description provided.