mirror of
https://github.com/project-zot/zot.git
synced 2025-01-06 22:40:28 -05:00
af222de108
Changes in this commit: A. There were nested conveys following the pattern: - outer convey was a positive test - inner conveys were negative tests The positive and negative tests did not depend on one another, but the positive test was repeated for each negative test. So for example if there was 1 positive test and 2 negative tests what go would do is: 1. execute the outer convey with the positive test 2. execute the 1st inner convey with the 1st negative test 3. execute the outer convey with the positive test 4. execute the 2nd inner convey with the 2nd negative test Since there were no dependencies between these tests they can be moved on the same level. B. The test function bringing up the controller for `TestServerCVEResponseGQL` was the same for `TestServerCVEResponse`, so I removed `TestServerCVEResponseGQL` and moved the Conveys under `TestServerCVEResponse`. This will save time on the initial TrivyDB download, since it's done only once when the controller starts. C. The `Convey("without flags", func() {` was actually the same as the test under which it was nested: `Convey("Test CVE invalid url port", t, func() {` no code differences so I removed it. D. Use the new test functions to start/stop and wait for the zot contoller to be reachable Signed-off-by: Andrei Aaron <aaaron@luxoft.com> |
||
---|---|---|
.. | ||
cli.go | ||
client.go | ||
client_elevated_test.go | ||
client_test.go | ||
config_cmd.go | ||
config_cmd_test.go | ||
config_reloader.go | ||
config_reloader_test.go | ||
cve_cmd.go | ||
cve_cmd_test.go | ||
discover.go | ||
extensions_test.go | ||
image_cmd.go | ||
image_cmd_test.go | ||
minimal.go | ||
repo_cmd.go | ||
root.go | ||
root_test.go | ||
searcher.go | ||
service.go | ||
stress_test.go |