-
Notifications
You must be signed in to change notification settings - Fork 43
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
Question: refactoring to fully use pytest #272
Comments
What is the problem with using Docker Compose? |
you have to start it up manually before the tests. so running |
Back to the first question: the reason for having a mix of different types of tests - not 100% sure if it's still relevant - was that Mocket as a testing tool has to be compatible with any tool around, especially if it comes from the standard library. So, if some tests are relying on |
to test for compatibility with pytest and stdlib.unittest maybe it would be good to cover that in dedicated tests? |
Mocket is not a framework people use to write software with. It's primarily a tool for testing, so tests are a first-class citizen in here, as important as the code itself. |
I'll leave tests exactly as they are then :) regarding docker-compose.
|
That's was I used to do. I even tried other services similar to |
Ah. I'm not talking about the service, but about the standalone Python package. |
The PyPI package is exactly what I use (through its Docker image): https://pypi.org/project/httpbin/ |
If you are considering spawning the service from Mocket testing code, I believe it's way cleaner keeping the two things separated. |
ok i can live with that. |
Isn't fixing the Bash script easier? :) |
"fixing" the bashscript wont do anything for me.
conceptually that's impossible on systems like mine, where the hosts-file just cannot be changed. which is what spinning the containers up from within python would be able to address, as both requirements would not be there anymore. |
What OS are you using? And how do you specify a new host pointing to a fixed IP? |
I still see simpler solutions, like using the IP of the container as a fall-back. |
I'm on nixos, i have to configure it in my system-configuration which then generates the hosts-file. but yeah, that's a me problem :P |
Using the hostname if we are able to add it, or the IP as a fall-back, should be enough. |
Never ever tried that animal. :) |
It used to be possible to only run the tests relying on Mocket with |
FYI I have just fixed |
would you be interested in me refactoring the tests to fully and consistently use pytest?
i also have some ideas on how to get rid of the need to run
docker compose
.The text was updated successfully, but these errors were encountered: