From 330ce87851a077dc1bdb48b23750dd6d98166b29 Mon Sep 17 00:00:00 2001 From: James Phillips Date: Tue, 26 Sep 2017 20:53:06 -0700 Subject: [PATCH] Gets rid of flaky clause in stats fetcher unit test. Given how the rutine is coded we can still get data so this wasn't a reliable thing to check. --- agent/consul/stats_fetcher_test.go | 8 -------- 1 file changed, 8 deletions(-) diff --git a/agent/consul/stats_fetcher_test.go b/agent/consul/stats_fetcher_test.go index 516d08c5e..e814647f8 100644 --- a/agent/consul/stats_fetcher_test.go +++ b/agent/consul/stats_fetcher_test.go @@ -92,12 +92,4 @@ func TestStatsFetcher(t *testing.T) { } } }() - - // Do a fetch with a canceled context and make sure we bail right away. - ctx, cancel := context.WithTimeout(context.Background(), time.Second) - cancel() - stats := s1.statsFetcher.Fetch(ctx, servers) - if len(stats) != 0 { - t.Fatalf("bad: %#v", stats) - } }