-
Notifications
You must be signed in to change notification settings - Fork 55
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
Improve Test fixtures #558
Comments
this is good. thanks @galvesribeiro 💯 (to be fair I think someone else suggested before as well. can't remember who though) a few details:
Just a brain dump 😅 I intrigued to see where we go from here 💯 |
That shouldn't be a problem. We could build, as part of the CI, a local container image using Also, we can have "experimental" builds that happens every time we merge something to main. Those could generate Docker images and push them to the container registry here on Github. But that ofc would need to be added to the server repository CI pipeline.
This will be trivial. All you would need is to have docker desktop installed on your machine (Mac/Windows/Linux) and it will be fine. The CI agent on GitHub Actions is actually a container which also support "Docker in Docker" meaning that we wouldn't have any issues running there as well.
Yes, we can do it all separated in a different fixture and pick up the tests that are more likely to fail than others. Once it is safe, we just swap the fixtures on the rest. |
that sounds quite good @galvesribeiro! My last whinge if I may, sorry 😬 I think it's also good to be able to run the server on Windows and test againsts that as an option. |
We can still use containers. Windows Containers is a thing, so we can still use the same API as long as we run the Windows tests on Windows agents. I never had to run Windows containers on GitHub Actions even tho I know there are Windows agents. I guess we will find out soon 💃🏻 |
Proposed change
We should adopt TestContainers to improve the test reliability in particular to spin up and down the servers.
Use case
Test Containers make it easy for us to manage instances of Nats to be used on unit tests and avoid manual management of processes. All that the test agent (CI machine, developer machine, etc) needs to have is the ability to run containers (i.e. Docker).
Contribution
I'll look on what it takes and write details later on here.
The text was updated successfully, but these errors were encountered: