-
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
Move integration tests towards schutzbot/run_tests.sh
#119
Comments
Hi @Gundersanne ,
It can output simple test results and generate a pretty html report(http://10.0.155.207/reports/report.html). And it's lite. Could you please check if it meets your expectation to replace the image-builder-tests binary package? Thanks! |
Nice! Thank you for that, always good to have proof of concepts. That said I think the ideal way to structure the integration tests is to follow what osbuild-composer does as much as possible. Obviously there would a lot fewer tests in image-builder , but since the For this a few steps are necessary though, we'd need to update the spec file to generate a tests subpackage and move the |
Hi @Gundersanne , I read the code in
And it only verify these "curl"s can get ok status, but not verify the contents. As you mentioned in #120 we may need more corner cases to make it more like a interface test(positive/negative test, and perhaps secure test). Here is a small group of cases I think we can test image-builder:
In such case, IMO language is not important, but having a test framework will be more convenience for running more test cases. (For bash, I also find a framework bats but I didn't use it before.). |
Hi @Gundersanne , I've add 3 simple demos of the integration tests:
Having a framework will be more convenient to run multiple test cases. But for the consistency, it's also OK to use the api.sh. Which one do you prefer? I'd like to add more cases after confirming the test framework. Thanks! |
Hey, Thank you! So I like option number 2, this would give us tap output, but lets us keep using tools that we're expecting other people to use when calling the api directly. Furthermore keeps the differences between composer and image-builder small enough I'd say. I still like option number 1 as well just because it's what composer does. I think I'd be fine with either 1 or 2 honestly. Just to note: to have a similar structure to composer this will require some spec file work too but I can do that afterwards, we can just invoke those tests from |
Hi, Is there any further work needed for this issue? Thanks! |
Hey, I'd say this is done! They're now invoked in the same way as in osbuild-composer. Thank you! |
Instead of calling
image-builder-tests
, let's remove that binary, and just start the container and usecurl
andjq
to tests the endpoints.The text was updated successfully, but these errors were encountered: