File tree 1 file changed +0
-23
lines changed
packages/spectacle/src/components
1 file changed +0
-23
lines changed Original file line number Diff line number Diff line change @@ -120,27 +120,4 @@ describe('<FitText />', () => {
120
120
expect ( textElement ) . toHaveStyle ( { color : defaultTheme . colors . secondary } ) ;
121
121
expect ( textElement ) . toHaveStyle ( { fontSize : 'h1' } ) ;
122
122
} ) ;
123
-
124
- it ( 'should scale text when container size changes' , ( ) => {
125
- // Simulate a container that's smaller than the text
126
- jest . mock ( 'use-resize-observer' , ( ) => {
127
- return { width : 100 , height : 100 } ;
128
- } ) ;
129
-
130
- const { container } = mountWithTheme (
131
- < FitText > Long text that needs scaling</ FitText >
132
- ) ;
133
- const scaledText = container . querySelector ( 'div[scale]' ) ;
134
- expect ( scaledText ) . toHaveStyle ( { transform : 'scale(1)' } ) ; // TODO: Not sure if this is a great test / expected.
135
- } ) ;
136
-
137
- it ( 'should center text in container' , ( ) => {
138
- const { container } = mountWithTheme ( < FitText > Centered text</ FitText > ) ;
139
- const fitContainer = container . firstChild ;
140
- expect ( fitContainer ) . toHaveStyle ( {
141
- display : 'flex' ,
142
- alignItems : 'center' ,
143
- justifyContent : 'center'
144
- } ) ;
145
- } ) ;
146
123
} ) ;
You can’t perform that action at this time.
0 commit comments