tests: switch to WithinDuration to improve test (#6860)
tests: switch to WithinDuration to improve test (#6860)

* Switch to WithinDuration to improve test

This test was flaky before because of the time logic. Now it uses
WithinDuration and should be correct.

Fixes https://github.com/hashicorp/consul/issues/6857.
42wim/consul,kingland/consul,scalp42/consul,hashicorp/consul,scalp42/consul,42wim/consul,hashicorp/consul,hashicorp/consul,scalp42/consul,kingland/consul,scalp42/consul,scalp42/consul,hashicorp/consul,kingland/consul,42wim/consul,kingland/consul,42wim/consul,42wim/consul,kingland/consul