wearefrank / frank-runner

Run any Frank with Tomcat
Apache License 2.0
16 stars 12 forks source link

Frank!Runner overwrites scenariosroot1 #16

Closed ricardovh closed 4 years ago

ricardovh commented 4 years ago

I have a setup for a project that almost matches https://github.com/ibissource/frank-runner#project-per-config, the main difference is that I do not run the configs separately as there are some dependencies between them, so I only run the entire application as a whole.

In my Test.properties I point the directory classloaders and scenariosrootX.dir to the correct directories. The Frank!Runner overwrites the scenariosroot1 properties, making those testcases unavailable.

jacodg commented 4 years ago

Not sure how I could change the Frank!Runner for this but currently you do have some options. You could add the following to your build.xml:

Or use scenariosroot2.directory instead of scenariosroot1.directory in your Test.properties.

P.s. a drawback of Test.properties is that every individual developer has to create this file. Isn't it possible to use StageSpecifics_LOC.properties?

ricardovh commented 4 years ago

We could indeed use scenariosroot2 and higher, but it is strange that the Frank!Runner as a server decides that it should set the scenariosroot1.

Problem is not limited to Test.properties, StageSpecifics will have the same problem as server properties have a higher priority than .properties.

jacodg commented 4 years ago

The location of the folder with test scenario's is dependent on the environment it runs in. And even whether you are running from Tomcat within Eclipse in Maven style or classic project setup, or running a Maven command to start Jetty or ... In the past the idea was to be able to configure all these possibilities from the application itself (with one or more of the Ibis .properties files). This is still possible but the idea of the Frank!Runner is to manage the location of the configuration, java and test files for the developer without changing the application and relieve the developer from setting up their environment. It would require a lot of logic in the Frank!Runner to be able to detect whether the application is setting these properties itself and what to do with it. But maybe we can make it configurable with a property or something. On the other hand we could also see whether the Frank!Runner could manage the settings you are now managing yourself. I'll try to contact you so you can show me your use case and we can discuss more in detail.

I didn't try to say StageSpecifics_LOC.properties is the solution for this problem. But more in general I would prefer to make settings work for everybody in the team. But you are probably constantly editing Test.properties to switch between settings so Test.properties is more appropriate for that.

ricardovh commented 4 years ago

Solved by commits 76ba6b6737834381da75010921ecbe68011d10f7 and 3635c540d2848436f52626c8823e850d07ec1ba8