Skip to content

Commit

Permalink
Merge pull request #17011 from webpack/issue-16155
Browse files Browse the repository at this point in the history
test: added test case
  • Loading branch information
TheLarkInn committed Apr 17, 2023
2 parents f1d25f4 + 50bb0c2 commit 8ce07a1
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/configCases/css/css-modules-in-node/index.js
Expand Up @@ -65,6 +65,9 @@ it("should allow to create css modules", done => {
VARS: prod
? "--my-app-491-DJ my-app-491-ms undefined my-app-491-cU"
: "--./style.module.css-LOCAL-COLOR ./style.module.css-VARS undefined ./style.module.css-globalVarsUpperCase",
inSupportScope: prod
? "my-app-491-FO"
: "./style.module.css-inSupportScope",
});
} catch (e) {
return done(e);
Expand Down
3 changes: 3 additions & 0 deletions test/configCases/css/css-modules/index.js
Expand Up @@ -68,6 +68,9 @@ it("should allow to create css modules", done => {
VARS: prod
? "--my-app-491-DJ my-app-491-ms undefined my-app-491-cU"
: "--./style.module.css-LOCAL-COLOR ./style.module.css-VARS undefined ./style.module.css-globalVarsUpperCase",
inSupportScope: prod
? "my-app-491-FO"
: "./style.module.css-inSupportScope",
});
} catch (e) {
return done(e);
Expand Down
6 changes: 6 additions & 0 deletions test/configCases/css/css-modules/style.module.css
Expand Up @@ -219,3 +219,9 @@
COLOR: VAR(--GLOBAR-COLOR);
--GLOBAR-COLOR: red;
}

@supports (top: env(safe-area-inset-top, 0)) {
.inSupportScope {
color: red;
}
}
1 change: 1 addition & 0 deletions test/configCases/css/css-modules/use-style.js
Expand Up @@ -31,4 +31,5 @@ export default {
supportsInMedia: style.displayFlexInSupportsInMedia,
displayFlexInSupportsInMediaUpperCase: style.displayFlexInSupportsInMediaUpperCase,
VARS: `${style["LOCAL-COLOR"]} ${style.VARS} ${style["GLOBAL-COLOR"]} ${style.globalVarsUpperCase}`,
inSupportScope: style.inSupportScope,
};

0 comments on commit 8ce07a1

Please sign in to comment.