I have a client I'm testing with Eureka and Spring Cloud Config clients included. When I run a client side test with my stub jar, the created stubrunner follows the default behavior of my client and attempts to connect to Eureka and Config Server. As fail-fast is also set, when it can't connect to Eureka or the default localhost:8888 config server, it terminates and fails the test.
My client under test runs with a standalone profile that turns off Eureka and Config clients.
It appears that the stubrunner container starts with a profile of development as when I setup configuration in bootstrap.yml for development to match my standalone profile, the stubrunner starts without issue, serves the stub data and the test completes successfully.
This development profile workaround is likely to cause problems for anyone who already has a profile of that name.
I have a project to demo this at https://github.com/mattreyuk/clientTest
I have a client I'm testing with Eureka and Spring Cloud Config clients included. When I run a client side test with my stub jar, the created stubrunner follows the default behavior of my client and attempts to connect to Eureka and Config Server. As
fail-fastis also set, when it can't connect to Eureka or the defaultlocalhost:8888config server, it terminates and fails the test.My client under test runs with a
standaloneprofile that turns off Eureka and Config clients.It appears that the stubrunner container starts with a profile of
developmentas when I setup configuration inbootstrap.ymlfordevelopmentto match mystandaloneprofile, the stubrunner starts without issue, serves the stub data and the test completes successfully.This
developmentprofile workaround is likely to cause problems for anyone who already has a profile of that name.I have a project to demo this at https://github.com/mattreyuk/clientTest