Skip to content
This repository was archived by the owner on Feb 18, 2022. It is now read-only.

add tests for variables with url() #262

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions test/basic.css
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ html {
--shadow: 0 6px 14px 0 color(var(--shadow-color) a(.15));
--font-family: "Open Sans", sans-serif;
color: var(--color);
--url: url("/my/path");
}

:root,
Expand Down Expand Up @@ -99,3 +100,7 @@ html {
.test--combined-selector {
color: var(--theme-color);
}

.test--variable-with-url {
background: var(--url);
}
6 changes: 6 additions & 0 deletions test/basic.expect.css
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ html {
--font-family: "Open Sans", sans-serif;
color: rgb(255, 0, 0);
color: var(--color);
--url: url("/my/path");
}

:root,
Expand Down Expand Up @@ -114,3 +115,8 @@ html {
color: #053;
color: var(--theme-color);
}

.test--variable-with-url {
background: url("/my/path");
background: var(--url);
}
6 changes: 6 additions & 0 deletions test/basic.import-is-empty.expect.css
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ html {
--font-family: "Open Sans", sans-serif;
color: rgb(255, 0, 0);
color: var(--color);
--url: url("/my/path");
}

:root,
Expand Down Expand Up @@ -114,3 +115,8 @@ html {
color: #053;
color: var(--theme-color);
}

.test--variable-with-url {
background: url("/my/path");
background: var(--url);
}
4 changes: 4 additions & 0 deletions test/basic.import-override.expect.css
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,7 @@
.test--combined-selector {
color: #053;
}

.test--variable-with-url {
background: url("/my/path");
}
6 changes: 6 additions & 0 deletions test/basic.import.expect.css
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ html {
--font-family: "Open Sans", sans-serif;
color: rgb(255, 0, 0);
color: var(--color);
--url: url("/my/path");
}

:root,
Expand Down Expand Up @@ -115,3 +116,8 @@ html {
color: #053;
color: var(--theme-color);
}

.test--variable-with-url {
background: url("/my/path");
background: var(--url);
}
4 changes: 4 additions & 0 deletions test/basic.preserve.expect.css
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,7 @@
.test--combined-selector {
color: #053;
}

.test--variable-with-url {
background: url("/my/path");
}
1 change: 1 addition & 0 deletions test/export-properties.css
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@
--shadow-color: rgb(255,0,0);
--shadow: 0 6px 14px 0 color(var(--shadow-color) a(.15));
--font-family: "Open Sans", sans-serif;
--url: url("/my/path");
--theme-color: #053;
}
1 change: 1 addition & 0 deletions test/export-properties.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ module.exports = {
'--shadow-color': 'rgb(255,0,0)',
'--shadow': '0 6px 14px 0 color(var(--shadow-color) a(.15))',
'--font-family': '"Open Sans", sans-serif',
'--url': 'url("/my/path")',
'--theme-color': '#053'
}
};
1 change: 1 addition & 0 deletions test/export-properties.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"--shadow-color": "rgb(255,0,0)",
"--shadow": "0 6px 14px 0 color(var(--shadow-color) a(.15))",
"--font-family": "\"Open Sans\", sans-serif",
"--url": "url(\"/my/path\")",
"--theme-color": "#053"
}
}
1 change: 1 addition & 0 deletions test/export-properties.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ export const customProperties = {
'--shadow-color': 'rgb(255,0,0)',
'--shadow': '0 6px 14px 0 color(var(--shadow-color) a(.15))',
'--font-family': '"Open Sans", sans-serif',
'--url': 'url("/my/path")',
'--theme-color': '#053'
};
1 change: 1 addition & 0 deletions test/export-properties.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ $margin: 0 10px 20px 30px;
$shadow-color: rgb(255,0,0);
$shadow: 0 6px 14px 0 color(var(--shadow-color) a(.15));
$font-family: "Open Sans", sans-serif;
$url: url("/my/path");
$theme-color: #053;