From f493682b76a6d0185ce5582eae11c7fcd388d62b Mon Sep 17 00:00:00 2001 From: Jonny Gerig Meyer Date: Wed, 5 Nov 2025 14:21:46 -0500 Subject: [PATCH 1/2] Upgrade sass and attempt to update tests --- package.json | 6 +- test/scss/assert/_values.scss | 9 +- test/scss/data/_details.scss | 8 +- yarn.lock | 190 +++++++++++++++++----------------- 4 files changed, 106 insertions(+), 107 deletions(-) diff --git a/package.json b/package.json index a9e6615..f7070c1 100644 --- a/package.json +++ b/package.json @@ -96,10 +96,10 @@ "eslint-plugin-simple-import-sort": "^12.1.1", "globals": "^16.5.0", "jest": "^30.2.0", - "mocha": "^11.7.4", + "mocha": "^11.7.5", "npm-run-all": "^4.1.5", - "sass": "1.90.0", - "sass-embedded": "1.90.0", + "sass": "^1.93.3", + "sass-embedded": "^1.93.3", "sassdoc": "^2.7.4", "sassdoc-theme-herman": "^6.0.2", "stylelint": "^16.25.0", diff --git a/test/scss/assert/_values.scss b/test/scss/assert/_values.scss index 4e7976b..b57667b 100644 --- a/test/scss/assert/_values.scss +++ b/test/scss/assert/_values.scss @@ -50,21 +50,20 @@ } @include it('Adding floats') { - @include assert-equal(0.1 + 0.2, 0.3, $inspect: true); + @include assert-equal(0.1 + 0.2, 0.3); } - @include it('Rounded numbers with $inspect') { - @include assert-equal(math.div(1, 3), 0.3333333333, $inspect: true); + @include it('Rounded numbers') { + @include assert-equal(math.div(1, 3), 0.3333333333333333); } - @include it('Rounded colors with $inspect') { + @include it('Rounded colors') { $origin: #246; $expected: rgb(53.125, 106.25, 159.375); @include assert-equal( color.adjust($origin, $lightness: 15%), $expected, - $inspect: true ); } diff --git a/test/scss/data/_details.scss b/test/scss/data/_details.scss index 6e4bb87..b6d6a27 100644 --- a/test/scss/data/_details.scss +++ b/test/scss/data/_details.scss @@ -28,14 +28,14 @@ @include assert { @include output(false) { @include context.context('assert', '[assert-equal] Test Assertion'); - @include details.fail-details(math.div(1, 3), 0.3333333333, not 'terminal'); + @include details.fail-details(math.div(1, 3), 0.3333333333333333, not 'terminal'); @include context.context-pop; } @include expect(false) { /* ✖ FAILED: [assert-equal] Test Assertion */ - /* - Output: [number] 0.3333333333 */ - /* - Expected: [number] 0.3333333333 */ + /* - Output: [number] 0.3333333333333333 */ + /* - Expected: [number] 0.3333333333333333 */ /* - Details: numbers may need to be rounded before comparison (set `$inspect: true` to compare output values) */ /* - Module: Fail Details */ /* - Test: Compiles full failure details */ @@ -105,7 +105,7 @@ @include it('Number Rounding') { $message: '- Details: numbers may need to be rounded before comparison (set `$inspect: true` to compare output values)'; - @include assert-equal(details.edgefail-notes(math.div(1, 3), 0.3333333333), $message); + @include assert-equal(details.edgefail-notes(math.div(1, 3), 0.3333333333333333), $message); } @include it('List Separators') { diff --git a/yarn.lock b/yarn.lock index 5013dcb..a72f214 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3195,11 +3195,11 @@ __metadata: linkType: hard "baseline-browser-mapping@npm:^2.8.19": - version: 2.8.24 - resolution: "baseline-browser-mapping@npm:2.8.24" + version: 2.8.25 + resolution: "baseline-browser-mapping@npm:2.8.25" bin: baseline-browser-mapping: dist/cli.js - checksum: 10/ea99b958242de7d9c714cc7139b67697f9b0731b292d3153578c988d98e919816cd515537db2fc56ea0918117d1524ac2c6baf860fb9a8bc7aa2adeed95582f7 + checksum: 10/a6af9dcf57b6c7209467b74a167e96c8ad4ba61ba930c66561008b45dc650701f760434634559cab3ff3580f8b1f28e717af8fd8a73440e52dee5c096d92e38f languageName: node linkType: hard @@ -4268,9 +4268,9 @@ __metadata: linkType: hard "electron-to-chromium@npm:^1.5.238": - version: 1.5.244 - resolution: "electron-to-chromium@npm:1.5.244" - checksum: 10/5a29ee295259c9161b62fe4d221cffa988e69a53021a19e460778cccc529716d4f0c9f5f42f1436260913b1dcd2e923cec3f8d6ae15a9af07ccde7df9ebb93b9 + version: 1.5.245 + resolution: "electron-to-chromium@npm:1.5.245" + checksum: 10/c51d901380d244355a3e939510d0516ef102f9f05bc2d4f0e8983a7e797ae79a720a7933217dd10921bac5cbe627085dd333c915a7647288853202ec411d4907 languageName: node linkType: hard @@ -7736,9 +7736,9 @@ __metadata: languageName: node linkType: hard -"mocha@npm:^11.7.4": - version: 11.7.4 - resolution: "mocha@npm:11.7.4" +"mocha@npm:^11.7.5": + version: 11.7.5 + resolution: "mocha@npm:11.7.5" dependencies: browser-stdout: "npm:^1.3.1" chokidar: "npm:^4.0.1" @@ -7764,7 +7764,7 @@ __metadata: bin: _mocha: bin/_mocha mocha: bin/mocha.js - checksum: 10/d4ad2faefe50d6eeb023fdbf2c1a2e5b07fed7d4240aac9175def7c034c879900e94ad38c5571c1d80ed462108afa6512e214280f8528a041bfd9c7fe467d35b + checksum: 10/878fcec45d79dad3ec01b896ae75eabd0075b8f91866b338b81b2ef8a2279f1e70fb07fc89054108a46864fbc1e6f6898dc31e64c033ded585748c5fcbf7e704 languageName: node linkType: hard @@ -9141,163 +9141,163 @@ __metadata: languageName: node linkType: hard -"sass-embedded-all-unknown@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-all-unknown@npm:1.90.0" +"sass-embedded-all-unknown@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-all-unknown@npm:1.93.3" dependencies: - sass: "npm:1.90.0" + sass: "npm:1.93.3" conditions: (!cpu=arm | !cpu=arm64 | !cpu=riscv64 | !cpu=x64) languageName: node linkType: hard -"sass-embedded-android-arm64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-android-arm64@npm:1.90.0" +"sass-embedded-android-arm64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-android-arm64@npm:1.93.3" conditions: os=android & cpu=arm64 languageName: node linkType: hard -"sass-embedded-android-arm@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-android-arm@npm:1.90.0" +"sass-embedded-android-arm@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-android-arm@npm:1.93.3" conditions: os=android & cpu=arm languageName: node linkType: hard -"sass-embedded-android-riscv64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-android-riscv64@npm:1.90.0" +"sass-embedded-android-riscv64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-android-riscv64@npm:1.93.3" conditions: os=android & cpu=riscv64 languageName: node linkType: hard -"sass-embedded-android-x64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-android-x64@npm:1.90.0" +"sass-embedded-android-x64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-android-x64@npm:1.93.3" conditions: os=android & cpu=x64 languageName: node linkType: hard -"sass-embedded-darwin-arm64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-darwin-arm64@npm:1.90.0" +"sass-embedded-darwin-arm64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-darwin-arm64@npm:1.93.3" conditions: os=darwin & cpu=arm64 languageName: node linkType: hard -"sass-embedded-darwin-x64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-darwin-x64@npm:1.90.0" +"sass-embedded-darwin-x64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-darwin-x64@npm:1.93.3" conditions: os=darwin & cpu=x64 languageName: node linkType: hard -"sass-embedded-linux-arm64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-linux-arm64@npm:1.90.0" +"sass-embedded-linux-arm64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-linux-arm64@npm:1.93.3" conditions: os=linux & cpu=arm64 languageName: node linkType: hard -"sass-embedded-linux-arm@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-linux-arm@npm:1.90.0" +"sass-embedded-linux-arm@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-linux-arm@npm:1.93.3" conditions: os=linux & cpu=arm languageName: node linkType: hard -"sass-embedded-linux-musl-arm64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-linux-musl-arm64@npm:1.90.0" +"sass-embedded-linux-musl-arm64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-linux-musl-arm64@npm:1.93.3" conditions: os=linux & cpu=arm64 languageName: node linkType: hard -"sass-embedded-linux-musl-arm@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-linux-musl-arm@npm:1.90.0" +"sass-embedded-linux-musl-arm@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-linux-musl-arm@npm:1.93.3" conditions: os=linux & cpu=arm languageName: node linkType: hard -"sass-embedded-linux-musl-riscv64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-linux-musl-riscv64@npm:1.90.0" +"sass-embedded-linux-musl-riscv64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-linux-musl-riscv64@npm:1.93.3" conditions: os=linux & cpu=riscv64 languageName: node linkType: hard -"sass-embedded-linux-musl-x64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-linux-musl-x64@npm:1.90.0" +"sass-embedded-linux-musl-x64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-linux-musl-x64@npm:1.93.3" conditions: os=linux & cpu=x64 languageName: node linkType: hard -"sass-embedded-linux-riscv64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-linux-riscv64@npm:1.90.0" +"sass-embedded-linux-riscv64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-linux-riscv64@npm:1.93.3" conditions: os=linux & cpu=riscv64 languageName: node linkType: hard -"sass-embedded-linux-x64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-linux-x64@npm:1.90.0" +"sass-embedded-linux-x64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-linux-x64@npm:1.93.3" conditions: os=linux & cpu=x64 languageName: node linkType: hard -"sass-embedded-unknown-all@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-unknown-all@npm:1.90.0" +"sass-embedded-unknown-all@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-unknown-all@npm:1.93.3" dependencies: - sass: "npm:1.90.0" + sass: "npm:1.93.3" conditions: (!os=android | !os=darwin | !os=linux | !os=win32) languageName: node linkType: hard -"sass-embedded-win32-arm64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-win32-arm64@npm:1.90.0" +"sass-embedded-win32-arm64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-win32-arm64@npm:1.93.3" conditions: os=win32 & cpu=arm64 languageName: node linkType: hard -"sass-embedded-win32-x64@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded-win32-x64@npm:1.90.0" +"sass-embedded-win32-x64@npm:1.93.3": + version: 1.93.3 + resolution: "sass-embedded-win32-x64@npm:1.93.3" conditions: os=win32 & cpu=x64 languageName: node linkType: hard -"sass-embedded@npm:1.90.0": - version: 1.90.0 - resolution: "sass-embedded@npm:1.90.0" +"sass-embedded@npm:^1.93.3": + version: 1.93.3 + resolution: "sass-embedded@npm:1.93.3" dependencies: "@bufbuild/protobuf": "npm:^2.5.0" buffer-builder: "npm:^0.2.0" colorjs.io: "npm:^0.5.0" immutable: "npm:^5.0.2" rxjs: "npm:^7.4.0" - sass-embedded-all-unknown: "npm:1.90.0" - sass-embedded-android-arm: "npm:1.90.0" - sass-embedded-android-arm64: "npm:1.90.0" - sass-embedded-android-riscv64: "npm:1.90.0" - sass-embedded-android-x64: "npm:1.90.0" - sass-embedded-darwin-arm64: "npm:1.90.0" - sass-embedded-darwin-x64: "npm:1.90.0" - sass-embedded-linux-arm: "npm:1.90.0" - sass-embedded-linux-arm64: "npm:1.90.0" - sass-embedded-linux-musl-arm: "npm:1.90.0" - sass-embedded-linux-musl-arm64: "npm:1.90.0" - sass-embedded-linux-musl-riscv64: "npm:1.90.0" - sass-embedded-linux-musl-x64: "npm:1.90.0" - sass-embedded-linux-riscv64: "npm:1.90.0" - sass-embedded-linux-x64: "npm:1.90.0" - sass-embedded-unknown-all: "npm:1.90.0" - sass-embedded-win32-arm64: "npm:1.90.0" - sass-embedded-win32-x64: "npm:1.90.0" + sass-embedded-all-unknown: "npm:1.93.3" + sass-embedded-android-arm: "npm:1.93.3" + sass-embedded-android-arm64: "npm:1.93.3" + sass-embedded-android-riscv64: "npm:1.93.3" + sass-embedded-android-x64: "npm:1.93.3" + sass-embedded-darwin-arm64: "npm:1.93.3" + sass-embedded-darwin-x64: "npm:1.93.3" + sass-embedded-linux-arm: "npm:1.93.3" + sass-embedded-linux-arm64: "npm:1.93.3" + sass-embedded-linux-musl-arm: "npm:1.93.3" + sass-embedded-linux-musl-arm64: "npm:1.93.3" + sass-embedded-linux-musl-riscv64: "npm:1.93.3" + sass-embedded-linux-musl-x64: "npm:1.93.3" + sass-embedded-linux-riscv64: "npm:1.93.3" + sass-embedded-linux-x64: "npm:1.93.3" + sass-embedded-unknown-all: "npm:1.93.3" + sass-embedded-win32-arm64: "npm:1.93.3" + sass-embedded-win32-x64: "npm:1.93.3" supports-color: "npm:^8.1.1" sync-child-process: "npm:^1.0.2" varint: "npm:^6.0.0" @@ -9340,7 +9340,7 @@ __metadata: optional: true bin: sass: dist/bin/sass.js - checksum: 10/dd2da775e2f78189ae9305b46fb73dcd21ee440b8a95566b780dcbbf117081287ade9c0fb5c9bc98742fbc49d21ed6ce4600675344afcd2ef6d1aae901fb67dd + checksum: 10/e2a1d6a31da76ce94df75f690a434ecd6467209eca6333951f1008a17d54693643e8a7cf2e82e0514f07f98b6de17dcf2b2fdadd5ad8abdac113c40c350fe154 languageName: node linkType: hard @@ -9366,12 +9366,12 @@ __metadata: globals: "npm:^16.5.0" jest: "npm:^30.2.0" jest-diff: "npm:^30.2.0" - mocha: "npm:^11.7.4" + mocha: "npm:^11.7.5" npm-run-all: "npm:^4.1.5" postcss: "npm:^8.5.6" prettier: "npm:^3.6.2" - sass: "npm:1.90.0" - sass-embedded: "npm:1.90.0" + sass: "npm:^1.93.3" + sass-embedded: "npm:^1.93.3" sassdoc: "npm:^2.7.4" sassdoc-theme-herman: "npm:^6.0.2" stylelint: "npm:^16.25.0" @@ -9389,9 +9389,9 @@ __metadata: languageName: unknown linkType: soft -"sass@npm:1.90.0": - version: 1.90.0 - resolution: "sass@npm:1.90.0" +"sass@npm:1.93.3, sass@npm:^1.93.3": + version: 1.93.3 + resolution: "sass@npm:1.93.3" dependencies: "@parcel/watcher": "npm:^2.4.1" chokidar: "npm:^4.0.0" @@ -9402,7 +9402,7 @@ __metadata: optional: true bin: sass: sass.js - checksum: 10/409236ad975fbf0ea5bbf256d7a11da52b94489873ede6317cd85a44be376a3332daf439b95b39ea5b78e6e94d630541db3d128f3fbaffe4a72a0e34545f219c + checksum: 10/41f23b10bb203ee46b82b880e566edc3264cd00b0424bb7293c6aedb66fd4d6b9b7a217e91f98fb4653eee6538150bbe1a663abde03ad69cd5172beebf108ae0 languageName: node linkType: hard From aef73f9e0ec3341f2866252921be0d9c58fcfa83 Mon Sep 17 00:00:00 2001 From: Miriam Suzanne Date: Wed, 5 Nov 2025 15:50:29 -0700 Subject: [PATCH 2/2] Remove $inspect option for assertions --- CHANGELOG.md | 5 ++++ sass/assert/_values.scss | 30 +++++------------------ sass/data/_details.scss | 46 +++++++++++++---------------------- test/css/test.css | 36 ++++++++++++--------------- test/scss/assert/_values.scss | 15 +----------- test/scss/data/_details.scss | 20 +++++++++------ 6 files changed, 58 insertions(+), 94 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0bdbb42..e5e67b2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # True Changelog +## 9.1.0 UNRELEASED + +- BREAKING: Remove the `$inspect` option from assertions, + since Sass has improved comparisons and changed inspection. + ## 9.1.0-alpha.0 (07/01/25) - FEATURE: Do not fail on non-standard at-rules (switch to postcss for css diff --git a/sass/assert/_values.scss b/sass/assert/_values.scss index 582e651..d800c59 100644 --- a/sass/assert/_values.scss +++ b/sass/assert/_values.scss @@ -91,9 +91,6 @@ /// @param {string} $description [null] - /// Description of the assertion being tested /// (a `null` of `false` value generates a default description) -/// @param {bool} $inspect [false] - -/// Optionally compare inspected values -/// (useful for comparing CSS output rather than Sass values) /// /// @example scss - /// @use 'sass:math'; @@ -102,20 +99,14 @@ /// math.div(8, 2), 4, /// 'You can optionally describe the assertion...'); /// } -@mixin assert-equal($assert, $expected, $description: null, $inspect: false) { +@mixin assert-equal($assert, $expected, $description: null) { @include utils.setup('assert-equal', $description); - - @if $inspect { - $assert: meta.inspect($assert); - $expected: meta.inspect($expected); - } - @include utils.result($assert, $expected); } /// @alias assert-equal -@mixin is-equal($assert, $expected, $description: null, $inspect: false) { - @include assert-equal($assert, $expected, $description, $inspect); +@mixin is-equal($assert, $expected, $description: null) { + @include assert-equal($assert, $expected, $description); } // Assert UnEqual @@ -133,9 +124,6 @@ /// @param {string} $description [null] - /// Description of the assertion being tested. /// A `null` of `false` value generates a default description. -/// @param {bool} $inspect [false] - -/// Optionally compare inspected values -/// (useful for comparing CSS output rather than Sass values) /// /// @example scss - /// @include true.test('Strings and numbers are not the same') { @@ -143,18 +131,12 @@ /// 1em, /// '1em'); /// } -@mixin assert-unequal($assert, $expected, $description: null, $inspect: false) { +@mixin assert-unequal($assert, $expected, $description: null) { @include utils.setup('assert-unequal', $description); - - @if $inspect { - $assert: meta.inspect($assert); - $expected: meta.inspect($expected); - } - @include utils.result($assert, $expected, 'unequal'); } /// @alias assert-unequal -@mixin not-equal($assert, $expected, $description: null, $inspect: false) { - @include assert-unequal($assert, $expected, $description, $inspect); +@mixin not-equal($assert, $expected, $description: null) { + @include assert-unequal($assert, $expected, $description); } diff --git a/sass/data/_details.scss b/sass/data/_details.scss index 0c49b46..8cf4555 100644 --- a/sass/data/_details.scss +++ b/sass/data/_details.scss @@ -103,49 +103,37 @@ $two-type: meta.type-of($two); $note: null; $pre: '- Details: '; - $inspect: '(set `$inspect: true` to compare output values)'; + + // Type + @if ($one-type != $two-type) { + $message: 'variable types do not match'; + + @return $pre + $message; + } // List Separators - @if ($one-type == 'list') and ($two-type == 'list') { + @if $one-type == 'list' { @if (list.join((), $one, comma) == list.join((), $two, comma)) { $message: 'list-separators do not match'; - $note: $pre + $message; + + @return $pre + $message; } } // String Quotes - @if ($one-type == 'string') and ($two-type == 'string') { + @if $one-type == 'string' { @if (string.unquote($one) == string.unquote($two)) { $message: 'string quotations do not match'; - $note: $pre + $message; - } - } - $one: if(($one-type == 'string'), string.unquote($one), $one); - $two: if(($two-type == 'string'), string.unquote($two), $two); - - @if (meta.inspect($one) == meta.inspect($two)) { - // Type - @if ($one-type != $two-type) { - $message: 'variable types do not match'; - $note: $pre + $message + ' ' + $inspect; + @return $pre + $message; } + } - // Rounding - $number: ($one-type == 'number') and ($two-type == 'number'); - $color: ($one-type == 'color') and ($two-type == 'color'); + @if list.index(('number', 'color'), $one-type) { + $message: '#{$one-type}s may need to be rounded before comparison'; - @if ($number or $color) { - $type: if($number, 'numbers', 'colors'); - $message: '#{$type} may need to be rounded before comparison'; - $note: $pre + $message + ' ' + $inspect; - } - - // Catch-All (I think this may not be currently possible) - @if (not $note) { - $note: $pre + $inspect; - } + @return $pre + $message; } - @return $note; + @return $pre; } diff --git a/test/css/test.css b/test/css/test.css index 643f7c9..01b756e 100644 --- a/test/css/test.css +++ b/test/css/test.css @@ -155,17 +155,17 @@ /* ASSERT: */ /* OUTPUT */ /* ✖ FAILED: [assert-equal] Test Assertion */ -/* - Output: [number] 0.3333333333 */ -/* - Expected: [number] 0.3333333333 */ -/* - Details: numbers may need to be rounded before comparison (set `$inspect: true` to compare output values) */ +/* - Output: [number] 0.3333333333333333 */ +/* - Expected: [number] 0.333 */ +/* - Details: numbers may need to be rounded before comparison */ /* - Module: Fail Details */ /* - Test: Compiles full failure details */ /* END_OUTPUT */ /* EXPECTED */ /* ✖ FAILED: [assert-equal] Test Assertion */ -/* - Output: [number] 0.3333333333 */ -/* - Expected: [number] 0.3333333333 */ -/* - Details: numbers may need to be rounded before comparison (set `$inspect: true` to compare output values) */ +/* - Output: [number] 0.3333333333333333 */ +/* - Expected: [number] 0.333 */ +/* - Details: numbers may need to be rounded before comparison */ /* - Module: Fail Details */ /* - Test: Compiles full failure details */ /* END_EXPECTED */ @@ -353,15 +353,11 @@ /* Test: Adding floats */ /* ✔ [assert-equal] Adding floats */ /* */ -/* Test: Rounded numbers with $inspect */ -/* ✔ [assert-equal] Rounded numbers with $inspect */ +/* Test: Rounded numbers */ +/* ✔ [assert-equal] Rounded numbers */ /* */ -/* Test: Rounded colors with $inspect */ -/* ✔ [assert-equal] Rounded colors with $inspect */ -/* */ -/* Test: Mismatched types with $inspect */ -/* ✔ [assert-unequal] normally unequal */ -/* ✔ [assert-equal] Mismatched types with $inspect */ +/* Test: Rounded colors */ +/* ✔ [assert-equal] Rounded colors */ /* */ /* Test: Supports is-equal alias */ /* ✔ [assert-equal] Supports is-equal alias */ @@ -375,8 +371,8 @@ /* Test: Mismatched types */ /* ✔ [assert-unequal] Mismatched types */ /* */ -/* Test: Mismatched units no longer needs $inspect */ -/* ✔ [assert-unequal] Mismatched units no longer needs $inspect */ +/* Test: Mismatched units */ +/* ✔ [assert-unequal] Mismatched units */ /* */ /* Test: Supports not-equal alias */ /* ✔ [assert-unequal] Supports not-equal alias */ @@ -875,14 +871,14 @@ /* */ /* */ /* # SUMMARY ---------- */ -/* 104 Tests: */ -/* - 83 Passed */ +/* 103 Tests: */ +/* - 82 Passed */ /* - 0 Failed */ /* - 21 Output to CSS */ /* Stats: */ /* - 40 Modules */ -/* - 104 Tests */ -/* - 132 Assertions */ +/* - 103 Tests */ +/* - 130 Assertions */ /* -------------------- */ /*# sourceMappingURL=test.css.map */ diff --git a/test/scss/assert/_values.scss b/test/scss/assert/_values.scss index b57667b..980e555 100644 --- a/test/scss/assert/_values.scss +++ b/test/scss/assert/_values.scss @@ -67,19 +67,6 @@ ); } - @include it('Mismatched types with $inspect') { - @include assert-unequal( - string.unquote('1rem'), - 1rem, - 'normally unequal' - ); - @include assert-equal( - string.unquote('1rem'), - 1rem, - $inspect: true - ); - } - @include it('Supports is-equal alias') { @include is-equal(5, math.div(10, 2)); } @@ -96,7 +83,7 @@ @include assert-unequal(string.unquote('1rem'), 1rem); } - @include it('Mismatched units no longer needs $inspect') { + @include it('Mismatched units') { @include assert-unequal(1, 1rem); } diff --git a/test/scss/data/_details.scss b/test/scss/data/_details.scss index b6d6a27..af0d06b 100644 --- a/test/scss/data/_details.scss +++ b/test/scss/data/_details.scss @@ -28,15 +28,15 @@ @include assert { @include output(false) { @include context.context('assert', '[assert-equal] Test Assertion'); - @include details.fail-details(math.div(1, 3), 0.3333333333333333, not 'terminal'); + @include details.fail-details(math.div(1, 3), 0.333, not 'terminal'); @include context.context-pop; } @include expect(false) { /* ✖ FAILED: [assert-equal] Test Assertion */ /* - Output: [number] 0.3333333333333333 */ - /* - Expected: [number] 0.3333333333333333 */ - /* - Details: numbers may need to be rounded before comparison (set `$inspect: true` to compare output values) */ + /* - Expected: [number] 0.333 */ + /* - Details: numbers may need to be rounded before comparison */ /* - Module: Fail Details */ /* - Test: Compiles full failure details */ } @@ -78,7 +78,7 @@ // EdgeFail Notes @include describe('Edgefail Notes') { @include it('Type mismatch') { - $message: '- Details: variable types do not match (set `$inspect: true` to compare output values)'; + $message: '- Details: variable types do not match'; @include assert-equal(details.edgefail-notes(1em, '1em'), $message); @@ -103,9 +103,12 @@ } @include it('Number Rounding') { - $message: '- Details: numbers may need to be rounded before comparison (set `$inspect: true` to compare output values)'; + $message: '- Details: numbers may need to be rounded before comparison'; - @include assert-equal(details.edgefail-notes(math.div(1, 3), 0.3333333333333333), $message); + @include assert-equal( + details.edgefail-notes(math.div(1, 3), 0.3), + $message + ); } @include it('List Separators') { @@ -114,6 +117,9 @@ $space: list.join((), 'one', space); $comma: list.join((), 'one', comma); - @include assert-equal(details.edgefail-notes($space, $comma), $message); + @include assert-equal( + details.edgefail-notes($space, $comma), + $message + ); } }