diff --git a/superset-frontend/packages/superset-ui-chart-controls/test/operators/utils/isDerivedSeries.test.ts b/superset-frontend/packages/superset-ui-chart-controls/test/operators/utils/isDerivedSeries.test.ts index 235f30e79b8a1..05a1d738abc89 100644 --- a/superset-frontend/packages/superset-ui-chart-controls/test/operators/utils/isDerivedSeries.test.ts +++ b/superset-frontend/packages/superset-ui-chart-controls/test/operators/utils/isDerivedSeries.test.ts @@ -83,3 +83,17 @@ test('should be false if time compare is not suffix', () => { }; expect(isDerivedSeries(series, formDataWithActualTypes)).toEqual(false); }); + +test('should be false if series name invalid', () => { + const series = { + id: 123, + name: 123, + data: [100], + }; + const formDataWithActualTypes = { + ...formData, + comparison_type: ComparisionType.Values, + time_compare: ['1 month ago', '1 month later'], + }; + expect(isDerivedSeries(series, formDataWithActualTypes)).toEqual(false); +});