Skip to content

Commit

Permalink
Adjust warning expectations to support sass/dart-sass#1323 (#1657)
Browse files Browse the repository at this point in the history
Co-authored-by: awjin <awjinahn@gmail.com>
  • Loading branch information
nex3 and Awjin authored May 22, 2021
1 parent 15c5cf1 commit 97cd39e
Show file tree
Hide file tree
Showing 45 changed files with 474 additions and 421 deletions.
2 changes: 1 addition & 1 deletion lib-js/compiler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ export class DartCompiler implements Compiler {

async compile(path: string, opts: string[]): Promise<Stdio> {
this.stdin.write(`!cd ${path}\n`)
this.stdin.write([...this.initArgs, ...opts].join(" ") + "\n")
this.stdin.write(["--verbose", ...this.initArgs, ...opts].join(" ") + "\n")

return {
stdout: (await this.stdout.next()).value,
Expand Down
18 changes: 14 additions & 4 deletions spec/core_functions/meta/call.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -78,15 +78,20 @@ a {
}

<===> string/local/warning
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Dart Sass 2.0.0. Use call(get-function("a")) instead.
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal in Dart Sass 2.0.0.

Recommendation: call(get-function("a"))

,
2 | a {b: call("a", 1)}
| ^^^^^^^^^^^^
'
input.scss 2:7 root stylesheet

<===> string/local/warning-libsass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Dart Sass 2.0.0. Use call(get-function("a")) instead.

<===>
================================================================================
<===> string/built_in/input.scss
Expand All @@ -98,15 +103,20 @@ a {
}

<===> string/built_in/warning
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Dart Sass 2.0.0. Use call(get-function("rgb")) instead.
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal in Dart Sass 2.0.0.

Recommendation: call(get-function("rgb"))

,
1 | a {b: call("rgb", 1, 2, 3)}
| ^^^^^^^^^^^^^^^^^^^^
'
input.scss 1:7 root stylesheet

<===> string/built_in/warning-libsass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Dart Sass 2.0.0. Use call(get-function("rgb")) instead.

<===>
================================================================================
<===> named/input.scss
Expand Down
40 changes: 20 additions & 20 deletions spec/css/moz_document/functions/interpolated.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -92,99 +92,99 @@

<===> warning
DEPRECATION WARNING on line 1, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
1 | / @-moz-document url(#{"sass-lang.com"}) {
2 | | a {type: unquoted full url}
3 | \ }
'

DEPRECATION WARNING on line 4, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
4 | / @-moz-document url(#{sa + ss}-lang.com) {
5 | | a {type: unquoted partial url}
6 | \ }
'

DEPRECATION WARNING on line 7, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
7 | / @-moz-document url("#{sa + ss}-lang.com") {
8 | | a {type: quoted partial url}
9 | \ }
'

DEPRECATION WARNING on line 11, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
11 | / @-moz-document url-prefix(#{"https://sass-lang.com/docs"}) {
12 | | a {type: unquoted full url-prefix}
13 | \ }
'

DEPRECATION WARNING on line 14, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
14 | / @-moz-document url-prefix(#{ht + tps}://sass-lang.com/docs) {
15 | | a {type: unquoted partial url-prefix}
16 | \ }
'

DEPRECATION WARNING on line 17, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
17 | / @-moz-document url-prefix("#{ht + tps}://sass-lang.com/docs") {
18 | | a {type: quoted partial url-prefix}
19 | \ }
'

DEPRECATION WARNING on line 21, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
21 | / @-moz-document domain(#{"sass-lang.com"}) {
22 | | a {type: unquoted full domain}
23 | \ }
'

DEPRECATION WARNING on line 24, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
24 | / @-moz-document domain(#{sa + ss}-lang.com) {
25 | | a {type: unquoted partial domain}
26 | \ }
'

DEPRECATION WARNING on line 27, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
27 | / @-moz-document domain("#{sa + ss}-lang.com") {
28 | | a {type: quoted partial domain}
29 | \ }
'

DEPRECATION WARNING on line 31, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
31 | / @-moz-document regexp("#{ht + tp}s:.*") {
32 | | a {type: regexp}
Expand Down
28 changes: 14 additions & 14 deletions spec/css/moz_document/functions/static.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -63,69 +63,69 @@

<===> warning
DEPRECATION WARNING on line 1, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
1 | / @-moz-document url(sass-lang.com) {
2 | | a {type: unquoted url}
3 | \ }
'

DEPRECATION WARNING on line 4, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
4 | / @-moz-document url("sass-lang.com") {
5 | | a {type: quoted url}
6 | \ }
'

DEPRECATION WARNING on line 8, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
8 | / @-moz-document url-prefix(https://sass-lang.com/docs) {
9 | | a {type: unquoted url-prefix}
10 | \ }
'

DEPRECATION WARNING on line 11, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
11 | / @-moz-document url-prefix("https://sass-lang.com/docs") {
12 | | a {type: quoted url-prefix}
13 | \ }
'

DEPRECATION WARNING on line 15, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
15 | / @-moz-document domain(sass-lang.com) {
16 | | a {type: unquoted domain}
17 | \ }
'

DEPRECATION WARNING on line 18, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
18 | / @-moz-document domain("sass-lang.com") {
19 | | a {type: quoted domain}
20 | \ }
'

DEPRECATION WARNING on line 22, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
22 | / @-moz-document regexp("https:.*") {
23 | | a {type: regexp}
Expand Down
4 changes: 2 additions & 2 deletions spec/css/moz_document/multi_function.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@

<===> warning
DEPRECATION WARNING on line 1, column 1 of input.scss:
@-moz-document is deprecated and support will be removed from Sass in a future
release. For details, see http://bit.ly/moz-document.
@-moz-document is deprecated and support will be removed in Dart Sass 2.0.0.

For details, see http://bit.ly/moz-document.
,
1 | / @-moz-document url(http://www.w3.org/),
2 | | url-prefix(http://www.w3.org/Style/),
Expand Down
3 changes: 2 additions & 1 deletion spec/libsass-closed-issues/issue_1060.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ foo {
<===> warning-dart-sass
DEPRECATION WARNING on line 4, column 5 of input.scss:
@elseif is deprecated and will not be supported in future Sass versions.
Use "@else if" instead.

Recommendation: @else if
,
4 | } @elseif true {
| ^^^^^^^
Expand Down
11 changes: 6 additions & 5 deletions spec/libsass-closed-issues/issue_1075.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,16 @@ foo {
}

<===> warning
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Sass 4.0. Use call(function-reference(lighten)) instead.
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal in Dart Sass 2.0.0.

<===> warning-dart-sass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Dart Sass 2.0.0. Use call(get-function("lighten")) instead.
Recommendation: call(get-function("lighten"))

,
4 | bar: call($name, $args...);
| ^^^^^^^^^^^^^^^^^^^^^
'
input.scss 4:8 root stylesheet

<===> warning-libsass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Sass 4.0. Use call(function-reference(lighten)) instead.
7 changes: 4 additions & 3 deletions spec/libsass-closed-issues/issue_1081.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,10 @@ after import-after {
}

<===> warning
DEPRECATION WARNING: As of Dart Sass 2.0.0, !global assignments won't be able to
declare new variables. Since this assignment is at the root of the stylesheet,
the !global flag is unnecessary and can safely be removed.
DEPRECATION WARNING: As of Dart Sass 2.0.0, !global assignments won't be able to declare new variables.

Since this assignment is at the root of the stylesheet, the !global flag is
unnecessary and can safely be removed.

,
1 | $foo: foo !global !default;
Expand Down
11 changes: 6 additions & 5 deletions spec/libsass-closed-issues/issue_1133/normal.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,16 @@ b {
}

<===> warning
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Sass 4.0. Use call(function-reference(foo)) instead.
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal in Dart Sass 2.0.0.

<===> warning-dart-sass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Dart Sass 2.0.0. Use call(get-function("foo")) instead.
Recommendation: call(get-function("foo"))

,
13 | $map: call("foo", (this: is, my: map));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
'
input.scss 13:11 root stylesheet

<===> warning-libsass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Sass 4.0. Use call(function-reference(foo)) instead.
11 changes: 6 additions & 5 deletions spec/libsass-closed-issues/issue_1133/vararg.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,16 @@ b {
}

<===> warning
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Sass 4.0. Use call(function-reference(foo)) instead.
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal in Dart Sass 2.0.0.

<===> warning-dart-sass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Dart Sass 2.0.0. Use call(get-function("foo")) instead.
Recommendation: call(get-function("foo"))

,
13 | $map: call("foo", (this: is, my: map)...);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
'
input.scss 13:9 root stylesheet

<===> warning-libsass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Sass 4.0. Use call(function-reference(foo)) instead.
19 changes: 10 additions & 9 deletions spec/libsass-closed-issues/issue_1266/max.hrx
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,9 @@ foo {
}

<===> error
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Sass 4.0. Use call(get-function("max")) instead.
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal in Dart Sass 2.0.0.

Error: "blah" is not a number for `max'
on line 3 of spec/libsass-closed-issues/issue_1266/max/input.scss
Use --trace for backtrace.

<===> error-dart-sass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Dart Sass 2.0.0. Use call(get-function(max)) instead.
Recommendation: call(get-function(max))

,
3 | bar: call(max, $foo...);
Expand All @@ -28,3 +21,11 @@ Error: blah is not a number.
| ^^^^^^^^^^^^^^^^^^
'
input.scss 3:8 root stylesheet

<===> error-libsass
DEPRECATION WARNING: Passing a string to call() is deprecated and will be illegal
in Sass 4.0. Use call(get-function("max")) instead.

Error: "blah" is not a number for `max'
on line 3 of spec/libsass-closed-issues/issue_1266/max/input.scss
Use --trace for backtrace.
Loading

0 comments on commit 97cd39e

Please sign in to comment.