Undoing the rename of prometheusProvider to make it easier to focus on the new functionality.

This commit is contained in:
Tony Compton 2018-06-27 22:16:31 -04:00
parent 5533ff7580
commit c30cc6c396
4 changed files with 16 additions and 16 deletions

View file

@ -95,7 +95,7 @@ func setupPrometheusProvider(t *testing.T) (provider.CustomMetricsProvider, *fak
namers, err := NamersFromConfig(cfg, restMapper())
require.NoError(t, err)
prov, _ := NewCustomPrometheusProvider(restMapper(), fakeKubeClient, fakeProm, namers, fakeProviderUpdateInterval)
prov, _ := NewPrometheusProvider(restMapper(), fakeKubeClient, fakeProm, namers, fakeProviderUpdateInterval)
containerSel := prom.MatchSeries("", prom.NameMatches("^container_.*"), prom.LabelNeq("container_name", "POD"), prom.LabelNeq("namespace", ""), prom.LabelNeq("pod_name", ""))
namespacedSel := prom.MatchSeries("", prom.LabelNeq("namespace", ""), prom.NameNotMatches("^container_.*"))
@ -141,7 +141,7 @@ func TestListAllMetrics(t *testing.T) {
fakeProm.acceptibleInterval = pmodel.Interval{Start: startTime, End: 0}
// update the metrics (without actually calling RunUntil, so we can avoid timing issues)
lister := prov.(*customPrometheusProvider).SeriesRegistry.(*cachingMetricsLister)
lister := prov.(*prometheusProvider).SeriesRegistry.(*cachingMetricsLister)
require.NoError(t, lister.updateMetrics())
// list/sort the metrics