|
| 1 | +// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html |
| 2 | + |
| 3 | +exports[`collect report with eslint-plugin NPM package > should run ESLint plugin and create report.json 1`] = ` |
| 4 | +{ |
| 5 | + "categories": [ |
| 6 | + { |
| 7 | + "description": "Lint rules that find **potential bugs** in your code.", |
| 8 | + "refs": [ |
| 9 | + { |
| 10 | + "plugin": "eslint", |
| 11 | + "slug": "problems", |
| 12 | + "type": "group", |
| 13 | + "weight": 1, |
| 14 | + }, |
| 15 | + ], |
| 16 | + "slug": "bug-prevention", |
| 17 | + "title": "Bug prevention", |
| 18 | + }, |
| 19 | + { |
| 20 | + "description": "Lint rules that promote **good practices** and consistency in your code.", |
| 21 | + "refs": [ |
| 22 | + { |
| 23 | + "plugin": "eslint", |
| 24 | + "slug": "suggestions", |
| 25 | + "type": "group", |
| 26 | + "weight": 1, |
| 27 | + }, |
| 28 | + ], |
| 29 | + "slug": "code-style", |
| 30 | + "title": "Code style", |
| 31 | + }, |
| 32 | + ], |
| 33 | + "packageName": "@code-pushup/core", |
| 34 | + "plugins": [ |
| 35 | + { |
| 36 | + "audits": [ |
| 37 | + { |
| 38 | + "description": "ESLint rule **no-unused-vars**.", |
| 39 | + "details": { |
| 40 | + "issues": [ |
| 41 | + { |
| 42 | + "message": "'unusedFn' is defined but never used.", |
| 43 | + "severity": "error", |
| 44 | + "source": { |
| 45 | + "file": "tmp/e2e/plugin-eslint-e2e/old-version/src/index.js", |
| 46 | + "position": { |
| 47 | + "endColumn": 18, |
| 48 | + "endLine": 1, |
| 49 | + "startColumn": 10, |
| 50 | + "startLine": 1, |
| 51 | + }, |
| 52 | + }, |
| 53 | + }, |
| 54 | + ], |
| 55 | + }, |
| 56 | + "displayValue": "1 error", |
| 57 | + "docsUrl": "https://eslint.org/docs/latest/rules/no-unused-vars", |
| 58 | + "score": 0, |
| 59 | + "slug": "no-unused-vars", |
| 60 | + "title": "Disallow unused variables", |
| 61 | + "value": 1, |
| 62 | + }, |
| 63 | + { |
| 64 | + "description": "ESLint rule **no-console**.", |
| 65 | + "details": { |
| 66 | + "issues": [ |
| 67 | + { |
| 68 | + "message": "Unexpected console statement.", |
| 69 | + "severity": "warning", |
| 70 | + "source": { |
| 71 | + "file": "tmp/e2e/plugin-eslint-e2e/old-version/src/index.js", |
| 72 | + "position": { |
| 73 | + "endColumn": 14, |
| 74 | + "endLine": 6, |
| 75 | + "startColumn": 3, |
| 76 | + "startLine": 6, |
| 77 | + }, |
| 78 | + }, |
| 79 | + }, |
| 80 | + ], |
| 81 | + }, |
| 82 | + "displayValue": "1 warning", |
| 83 | + "docsUrl": "https://eslint.org/docs/latest/rules/no-console", |
| 84 | + "score": 0, |
| 85 | + "slug": "no-console", |
| 86 | + "title": "Disallow the use of \`console\`", |
| 87 | + "value": 1, |
| 88 | + }, |
| 89 | + { |
| 90 | + "description": "ESLint rule **no-undef**.", |
| 91 | + "details": { |
| 92 | + "issues": [], |
| 93 | + }, |
| 94 | + "displayValue": "passed", |
| 95 | + "docsUrl": "https://eslint.org/docs/latest/rules/no-undef", |
| 96 | + "score": 1, |
| 97 | + "slug": "no-undef", |
| 98 | + "title": "Disallow the use of undeclared variables unless mentioned in \`/*global */\` comments", |
| 99 | + "value": 0, |
| 100 | + }, |
| 101 | + ], |
| 102 | + "description": "Official Code PushUp ESLint plugin", |
| 103 | + "docsUrl": "https://www.npmjs.com/package/@code-pushup/eslint-plugin", |
| 104 | + "groups": [ |
| 105 | + { |
| 106 | + "description": "Code that either will cause an error or may cause confusing behavior. Developers should consider this a high priority to resolve.", |
| 107 | + "refs": [ |
| 108 | + { |
| 109 | + "slug": "no-unused-vars", |
| 110 | + "weight": 1, |
| 111 | + }, |
| 112 | + { |
| 113 | + "slug": "no-undef", |
| 114 | + "weight": 1, |
| 115 | + }, |
| 116 | + ], |
| 117 | + "slug": "problems", |
| 118 | + "title": "Problems", |
| 119 | + }, |
| 120 | + { |
| 121 | + "description": "Something that could be done in a better way but no errors will occur if the code isn't changed.", |
| 122 | + "refs": [ |
| 123 | + { |
| 124 | + "slug": "no-console", |
| 125 | + "weight": 1, |
| 126 | + }, |
| 127 | + ], |
| 128 | + "slug": "suggestions", |
| 129 | + "title": "Suggestions", |
| 130 | + }, |
| 131 | + ], |
| 132 | + "icon": "eslint", |
| 133 | + "packageName": "@code-pushup/eslint-plugin", |
| 134 | + "slug": "eslint", |
| 135 | + "title": "ESLint", |
| 136 | + }, |
| 137 | + ], |
| 138 | +} |
| 139 | +`; |
0 commit comments