Commit ec2086ca authored by rpereira2's avatar rpereira2

Correct references to ee prometheus_metrics js

parent d88f6a0f
import IntegrationSettingsForm from '~/integrations/integration_settings_form';
import PrometheusMetrics from 'ee_else_ce/prometheus_metrics/prometheus_metrics';
import PrometheusMetrics from '~/prometheus_metrics/custom_metrics';
import PrometheusAlerts from '~/prometheus_alerts';
import initAlertsSettings from '~/alerts_service_settings';
......
import $ from 'jquery';
import { escape, sortBy } from 'lodash';
import PrometheusMetrics from '~/prometheus_metrics/prometheus_metrics';
import PrometheusMetrics from './prometheus_metrics';
import PANEL_STATE from './constants';
import axios from '~/lib/utils/axios_utils';
import { s__ } from '~/locale';
import { capitalizeFirstCharacter } from '~/lib/utils/text_utility';
export default class EEPrometheusMetrics extends PrometheusMetrics {
export default class CustomMetrics extends PrometheusMetrics {
constructor(wrapperSelector) {
super(wrapperSelector);
this.customMetrics = [];
......@@ -106,7 +106,7 @@ export default class EEPrometheusMetrics extends PrometheusMetrics {
const sortedMetrics = sortBy(this.customMetrics.map(capitalizeGroup), ['group', 'title']);
sortedMetrics.forEach(metric => {
this.$monitoredCustomMetricsList.append(EEPrometheusMetrics.customMetricTemplate(metric));
this.$monitoredCustomMetricsList.append(CustomMetrics.customMetricTemplate(metric));
});
this.$monitoredCustomMetricsCount.text(this.customMetrics.length);
......
import MockAdapter from 'axios-mock-adapter';
import PrometheusMetrics from 'ee/prometheus_metrics/prometheus_metrics';
import PrometheusMetrics from '~/prometheus_metrics/custom_metrics';
import axios from '~/lib/utils/axios_utils';
import PANEL_STATE from '~/prometheus_metrics/constants';
import metrics from './mock_data';
describe('PrometheusMetrics EE', () => {
describe('PrometheusMetrics', () => {
const FIXTURE = 'services/prometheus/prometheus_service.html';
const customMetricsEndpoint =
'http://test.host/frontend-fixtures/services-project/prometheus/metrics';
......@@ -23,7 +23,7 @@ describe('PrometheusMetrics EE', () => {
mock.restore();
});
describe('Custom Metrics EE', () => {
describe('Custom Metrics', () => {
let prometheusMetrics;
beforeEach(() => {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment