diff --git a/.betterer.eslint.config.js b/.betterer.eslint.config.js
index 32f06b160a4..8cda8335a07 100644
--- a/.betterer.eslint.config.js
+++ b/.betterer.eslint.config.js
@@ -97,7 +97,7 @@ module.exports = [
},
{
files: ['**/*.{ts,tsx}'],
- ignores: ['**/*.{test,spec}.{ts,tsx}', '**/__mocks__/**', '**/public/test/**'],
+ ignores: ['**/*.{test,spec}.{ts,tsx}', '**/__mocks__/**', '**/public/test/**', '**/mocks.{ts,tsx}'],
rules: {
'@typescript-eslint/consistent-type-assertions': ['error', { assertionStyle: 'never' }],
},
diff --git a/.betterer.results b/.betterer.results
index 27874e03865..dd37a8ffa5e 100644
--- a/.betterer.results
+++ b/.betterer.results
@@ -1440,14 +1440,6 @@ exports[`better eslint`] = {
[0, 0, 0, "Do not use any type assertions.", "0"],
[0, 0, 0, "No untranslated strings. Wrap text with ", "1"]
],
- "public/app/features/alerting/unified/mocks.ts:5381": [
- [0, 0, 0, "Do not use any type assertions.", "0"],
- [0, 0, 0, "Do not use any type assertions.", "1"],
- [0, 0, 0, "Do not use any type assertions.", "2"],
- [0, 0, 0, "Do not use any type assertions.", "3"],
- [0, 0, 0, "Do not use any type assertions.", "4"],
- [0, 0, 0, "Unexpected any. Specify a different type.", "5"]
- ],
"public/app/features/alerting/unified/rule-list/components/AlertRuleListItem.tsx:5381": [
[0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"]
],
diff --git a/public/app/features/alerting/unified/mocks.ts b/public/app/features/alerting/unified/mocks.ts
index a5658f18123..7c8e5374a5d 100644
--- a/public/app/features/alerting/unified/mocks.ts
+++ b/public/app/features/alerting/unified/mocks.ts
@@ -10,7 +10,7 @@ import {
ReducerID,
} from '@grafana/data';
import { config } from '@grafana/runtime';
-import { defaultDashboard } from '@grafana/schema';
+import { DataQuery, defaultDashboard } from '@grafana/schema';
import { contextSrv } from 'app/core/services/context_srv';
import { MOCK_GRAFANA_ALERT_RULE_TITLE } from 'app/features/alerting/unified/mocks/server/handlers/grafanaRuler';
import { ExpressionQuery, ExpressionQueryType, ReducerMode } from 'app/features/expressions/types';
@@ -125,7 +125,7 @@ export const mockRulerGrafanaRule = (
datasourceUid: '123',
refId: 'A',
queryType: 'huh',
- model: {} as any,
+ model: {} as unknown as DataQuery,
},
],
...partialDef,