@@ -21,7 +21,7 @@ function config(overrides) {
2121 } )
2222}
2323
24- test . only ( 'options are not required' , ( ) => {
24+ test ( 'options are not required' , ( ) => {
2525 const { components } = processPlugins ( [ container ( ) ] , config ( ) )
2626
2727 expect ( css ( components ) ) . toMatchCss ( `
@@ -45,7 +45,7 @@ test.only('options are not required', () => {
4545 ` )
4646} )
4747
48- test . only ( 'screens can be passed explicitly' , ( ) => {
48+ test ( 'screens can be passed explicitly' , ( ) => {
4949 const { components } = processPlugins (
5050 [ container ( ) ] ,
5151 config ( {
@@ -72,7 +72,7 @@ test.only('screens can be passed explicitly', () => {
7272 ` )
7373} )
7474
75- test . only ( 'screens are ordered ascending by min-width' , ( ) => {
75+ test ( 'screens are ordered ascending by min-width' , ( ) => {
7676 const { components } = processPlugins (
7777 [ container ( ) ] ,
7878 config ( {
@@ -99,7 +99,7 @@ test.only('screens are ordered ascending by min-width', () => {
9999 ` )
100100} )
101101
102- test . only ( 'screens are deduplicated by min-width' , ( ) => {
102+ test ( 'screens are deduplicated by min-width' , ( ) => {
103103 const { components } = processPlugins (
104104 [ container ( ) ] ,
105105 config ( {
@@ -130,7 +130,7 @@ test.only('screens are deduplicated by min-width', () => {
130130 ` )
131131} )
132132
133- test . only ( 'the container can be centered by default' , ( ) => {
133+ test ( 'the container can be centered by default' , ( ) => {
134134 const { components } = processPlugins (
135135 [ container ( ) ] ,
136136 config ( {
@@ -167,7 +167,7 @@ test.only('the container can be centered by default', () => {
167167 ` )
168168} )
169169
170- test . only ( 'horizontal padding can be included by default' , ( ) => {
170+ test ( 'horizontal padding can be included by default' , ( ) => {
171171 const { components } = processPlugins (
172172 [ container ( ) ] ,
173173 config ( {
@@ -204,7 +204,7 @@ test.only('horizontal padding can be included by default', () => {
204204 ` )
205205} )
206206
207- test . only ( 'responsive horizontal padding can be included by default' , ( ) => {
207+ test ( 'responsive horizontal padding can be included by default' , ( ) => {
208208 const { components } = processPlugins (
209209 [ container ( ) ] ,
210210 config ( {
@@ -258,7 +258,7 @@ test.only('responsive horizontal padding can be included by default', () => {
258258 ` )
259259} )
260260
261- test . only ( 'setting all options at once' , ( ) => {
261+ test ( 'setting all options at once' , ( ) => {
262262 const { components } = processPlugins (
263263 [ container ( ) ] ,
264264 config ( {
@@ -292,3 +292,39 @@ test.only('setting all options at once', () => {
292292 }
293293 ` )
294294} )
295+
296+ test ( 'container can use variants' , ( ) => {
297+ const { components } = processPlugins (
298+ [ container ( ) ] ,
299+ config ( {
300+ theme : {
301+ container : {
302+ screens : [ '400px' , '500px' ] ,
303+ } ,
304+ } ,
305+ variants : {
306+ container : [ 'responsive' , 'hover' ] ,
307+ } ,
308+ } )
309+ )
310+
311+ expect ( css ( components ) ) . toMatchCss ( `
312+ @layer components {
313+ @variants responsive, hover {
314+ .container {
315+ width: 100%
316+ }
317+ @media (min-width: 400px) {
318+ .container {
319+ max-width: 400px
320+ }
321+ }
322+ @media (min-width: 500px) {
323+ .container {
324+ max-width: 500px
325+ }
326+ }
327+ }
328+ }
329+ ` )
330+ } )
0 commit comments