diff --git a/.changeset/sixty-pants-repeat.md b/.changeset/sixty-pants-repeat.md new file mode 100644 index 00000000..1d9a7cd7 --- /dev/null +++ b/.changeset/sixty-pants-repeat.md @@ -0,0 +1,5 @@ +--- +'@shopify/stylelint-plugin': patch +--- + +Updated deprecated rules diff --git a/packages/stylelint-plugin/index.js b/packages/stylelint-plugin/index.js index c78721dc..6b608853 100644 --- a/packages/stylelint-plugin/index.js +++ b/packages/stylelint-plugin/index.js @@ -476,11 +476,11 @@ module.exports = { // Require a single space or disallow whitespace after the closing brace of @if statements. 'scss/at-if-closing-brace-space-after': 'always-intermediate', // Disallow leading underscore in partial names in @import. - 'scss/at-import-no-partial-leading-underscore': true, + 'scss/load-no-partial-leading-underscore': true, // Disallow unneeded `!= null` in if expressions (`@if $x != null` can be simplified to `@if $x`) 'scss/at-if-no-null': true, // Specify blacklist of disallowed file extensions for partial names in @import commands. - 'scss/at-import-partial-extension-blacklist': ['scss'], + 'scss/at-import-partial-extension-disallowed-list': ['scss'], // Specify whitelist of allowed file extensions for partial names in @import commands. 'scss/at-import-partial-extension-whitelist': null, // Require using `@each $key, $value in $list` instead of getting the value inside the loop diff --git a/packages/stylelint-plugin/tests/config-e2e.test.js b/packages/stylelint-plugin/tests/config-e2e.test.js index 25bd5ab9..39aca681 100644 --- a/packages/stylelint-plugin/tests/config-e2e.test.js +++ b/packages/stylelint-plugin/tests/config-e2e.test.js @@ -15,12 +15,6 @@ describe('stylelint-plugin E2E Tests', () => { const result = runStylelint('value-keyword-case.*.scss'); const expectedResult = ` -Deprecation warnings: - - The "scss/at-import-no-partial-leading-underscore" rule is deprecated. - - 'at-import-no-partial-leading-underscore' has been deprecated, and will be removed in '7.0'. Use 'load-no-partial-leading-underscore' instead. See: https://github.com/stylelint-scss/stylelint-scss/blob/v5.2.1/src/rules/at-import-no-partial-leading-underscore/README.md - - The "scss/at-import-partial-extension-blacklist" rule is deprecated. - - 'at-import-partial-extension-blacklist' has been deprecated, and will be removed in '7.0'. Use 'at-import-partial-extension-disallowed-list' instead. See: https://github.com/stylelint-scss/stylelint-scss/blob/v6.1.0/src/rules/at-import-partial-extension-blacklist/README.md - value-keyword-case.invalid.scss 1:7 ✖ Expected "Value" to be "value" value-keyword-case 2:7 ✖ Expected "VALUE" to be "value" value-keyword-case @@ -42,12 +36,6 @@ value-keyword-case.invalid.scss // trailing whitespace and editors really want to remove that trailing // whitespace when saving the file const expectedResult = ` -Deprecation warnings: - - The "scss/at-import-no-partial-leading-underscore" rule is deprecated. - - 'at-import-no-partial-leading-underscore' has been deprecated, and will be removed in '7.0'. Use 'load-no-partial-leading-underscore' instead. See: https://github.com/stylelint-scss/stylelint-scss/blob/v5.2.1/src/rules/at-import-no-partial-leading-underscore/README.md - - The "scss/at-import-partial-extension-blacklist" rule is deprecated. - - 'at-import-partial-extension-blacklist' has been deprecated, and will be removed in '7.0'. Use 'at-import-partial-extension-disallowed-list' instead. See: https://github.com/stylelint-scss/stylelint-scss/blob/v6.1.0/src/rules/at-import-partial-extension-blacklist/README.md - scss.invalid.scss 6:5 ✖ Expected ".n3" to have no more than 2 classes selector-max-class 6:5 ✖ Expected ".n3" to have no more than 1 combinator selector-max-combinators