File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -115,9 +115,13 @@ describe('<ConsoleMessage />', function() {
115
115
116
116
describe ( '<Console />' , function ( ) {
117
117
describe ( '[Property] autofocus: ' , function ( ) {
118
- it ( 'Has class `react-console-nofocus` on mount when autofocus undefined' , function ( ) {
118
+ it ( 'Has class `react-console-nofocus` until clicked when autofocus is undefined' , function ( ) {
119
119
var wrapper = enzyme . mount ( < Console /> ) ;
120
120
expect ( wrapper . find ( '.react-console-nofocus' ) ) . length ( 1 ) ;
121
+ expect ( wrapper . find ( '.react-console-focus' ) ) . length ( 0 ) ;
122
+ wrapper . simulate ( 'click' ) ;
123
+ expect ( wrapper . find ( '.react-console-focus' ) ) . length ( 1 ) ;
124
+ expect ( wrapper . find ( '.react-console-nofocus' ) ) . length ( 0 ) ;
121
125
} ) ;
122
126
it ( 'Has class `react-console-focus` on mount when autofocus=true' , function ( ) {
123
127
var wrapper = enzyme . mount ( < Console autofocus = { true } /> ) ;
You can’t perform that action at this time.
0 commit comments