contour
contour copied to clipboard
internal/dag: merge builder_test and status_test
Currently we test the DAG builder's output via buider_test.go
, we also test the status output via status_test.go
. Both of these tests do the same thing -- take some k8s objects, feed them to a KubernetesCache
, pass that cache to a builder, build a dag, compare the output.
Currently adding a test for status means doing that hop/skip/jump in status_test.go
, but if you also changed the code in builder.go
, then you should by right be adding a test in builder_test.go
as well.
This is double handling and means neither test suite are complete. What we should do is merge the status output checking into builder_test.go
so that for each builder test we assert the resultant dag, and the status outputs.