| The code added on #818 depends on map sorting to return a static reason for service annotation changes. To avoid tests flakiness and map sorting the tests include a `strings.HasPrefix` instead of comparing the whole string. One of the test cases, `service_removes_a_custom_annotation,_adds_a_new_one_and_change_another`, is trying to test the whole reason string. This commit replaces the test case reason, for only the reason prefix. It removes the flakiness from the tests. As all the cases (annotation adding, removing and value changing) are tested before, it's safe to test only prefixes. Also, it renames the test name from `TestServiceAnnotations` to `TestSameService` and introduces a better description in case of test failure, describing that only prefixes are tested. | ||
|---|---|---|
| .. | ||
| k8sutil.go | ||
| k8sutil_test.go | ||