jest-preset-stylelint 5.0.0 → 5.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/getTestRule.js CHANGED
@@ -83,12 +83,10 @@ module.exports = function getTestRule(options = {}) {
83
83
  }
84
84
 
85
85
  if (expected.endLine !== undefined) {
86
- // @ts-expect-error -- TODO: `warning.endLine` is not implemented. See stylelint/stylelint#5725
87
86
  expect(warning.endLine).toBe(expected.endLine);
88
87
  }
89
88
 
90
89
  if (expected.endColumn !== undefined) {
91
- // @ts-expect-error -- TODO: `warning.endColumn` is not implemented. See stylelint/stylelint#5725
92
90
  expect(warning.endColumn).toBe(expected.endColumn);
93
91
  }
94
92
  });
package/index.d.ts CHANGED
@@ -86,7 +86,7 @@ export type TestSchema = {
86
86
  /**
87
87
  * Config to pass to the rule.
88
88
  */
89
- config: unknown[];
89
+ config: unknown;
90
90
 
91
91
  /**
92
92
  * Accept test cases.
@@ -149,13 +149,13 @@ export type TestSchema = {
149
149
  /**
150
150
  * Test a rule with the specified schema.
151
151
  */
152
- export declare function testRule(schema: TestSchema): void;
152
+ export type TestRule = (schema: TestSchema) => void;
153
153
 
154
154
  /**
155
155
  * Create a `testRule()` function with any specified plugins.
156
156
  */
157
- export function getTestRule(options?: { plugins?: TestSchema['plugins'] }): typeof testRule;
157
+ export function getTestRule(options?: { plugins?: TestSchema['plugins'] }): TestRule;
158
158
 
159
159
  declare global {
160
- var testRule: typeof testRule;
160
+ var testRule: TestRule;
161
161
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jest-preset-stylelint",
3
- "version": "5.0.0",
3
+ "version": "5.0.3",
4
4
  "description": "Jest preset for Stylelint plugins.",
5
5
  "keywords": [
6
6
  "stylelint",
@@ -55,21 +55,21 @@
55
55
  "devDependencies": {
56
56
  "@stylelint/prettier-config": "^2.0.0",
57
57
  "@stylelint/remark-preset": "^3.0.0",
58
- "@types/jest": "^27.4.0",
59
- "eslint": "^8.9.0",
58
+ "@types/jest": "^27.4.1",
59
+ "eslint": "^8.14.0",
60
60
  "eslint-config-stylelint": "^15.0.0",
61
61
  "husky": "^7.0.4",
62
- "jest": "^27.5.1",
63
- "lint-staged": "^12.3.4",
64
- "np": "^7.6.0",
62
+ "jest": "^28.0.3",
63
+ "lint-staged": "^12.4.1",
64
+ "np": "^7.6.1",
65
65
  "npm-run-all": "^4.1.5",
66
- "prettier": "^2.5.1",
66
+ "prettier": "^2.6.2",
67
67
  "remark-cli": "^10.0.1",
68
- "stylelint": "^14.5.1",
69
- "typescript": "^4.5.5"
68
+ "stylelint": "^14.8.1",
69
+ "typescript": "^4.6.4"
70
70
  },
71
71
  "peerDependencies": {
72
- "jest": "^25.3.0 || ^26.0.1 || ^27.0.1"
72
+ "jest": "^25.3.0 || ^26.0.1 || ^27.0.1 || ^28.0.2"
73
73
  },
74
74
  "engines": {
75
75
  "node": "^12.20.0 || ^14.13.1 || >=16.0.0"