@@ -442,45 +442,43 @@ describe('<Preferences />', () => {
442
442
) ;
443
443
} ) ;
444
444
} ) ;
445
+ describe ( 'start wordwrap at false' , ( ) => {
446
+ it ( 'wordwrap toggle, starting at false' , ( ) => {
447
+ // render the component with wordwrap prop set to false
448
+ subject ( { wordwrap : false } ) ;
445
449
446
- describe ( 'start linewrap at false' , ( ) => {
447
- it ( 'linewrap toggle, starting at false' , ( ) => {
448
- // render the component with linewrap prop set to false
449
- subject ( { linewrap : false } ) ;
450
-
451
- // get ahold of the radio buttons for toggling linewrap
452
- const linewrapRadioFalse = screen . getByRole ( 'radio' , {
453
- name : / l i n e w r a p o f f / i
450
+ // get ahold of the radio buttons for toggling wordwrap
451
+ const wordwrapRadioFalse = screen . getByRole ( 'radio' , {
452
+ name : / w o r d w r a p o f f / i
454
453
} ) ;
455
- const linewrapRadioTrue = screen . getByRole ( 'radio' , {
456
- name : / l i n e w r a p o n / i
454
+ const wordwrapRadioTrue = screen . getByRole ( 'radio' , {
455
+ name : / w o r d w r a p o n / i
457
456
} ) ;
458
457
459
458
testToggle (
460
- linewrapRadioFalse ,
461
- linewrapRadioTrue ,
459
+ wordwrapRadioFalse ,
460
+ wordwrapRadioTrue ,
462
461
props . setLinewrap ,
463
462
true
464
463
) ;
465
464
} ) ;
466
465
} ) ;
466
+ describe ( 'start wordwrap at true' , ( ) => {
467
+ it ( 'wordwrap toggle, starting at true' , ( ) => {
468
+ // render the component with wordwrap prop set to true
469
+ subject ( { wordwrap : true } ) ;
467
470
468
- describe ( 'start linewrap at true' , ( ) => {
469
- it ( 'linewrap toggle, starting at true' , ( ) => {
470
- // render the component with linewrap prop set to false
471
- subject ( { linewrap : true } ) ;
472
-
473
- // get ahold of the radio buttons for toggling linewrap
474
- const linewrapRadioFalse = screen . getByRole ( 'radio' , {
475
- name : / l i n e w r a p o f f / i
471
+ // get ahold of the radio buttons for toggling wordwrap
472
+ const wordwrapRadioFalse = screen . getByRole ( 'radio' , {
473
+ name : / w o r d w r a p o f f / i
476
474
} ) ;
477
- const linewrapRadioTrue = screen . getByRole ( 'radio' , {
478
- name : / l i n e w r a p o n / i
475
+ const wordwrapRadioTrue = screen . getByRole ( 'radio' , {
476
+ name : / w o r d w r a p o n / i
479
477
} ) ;
480
478
481
479
testToggle (
482
- linewrapRadioTrue ,
483
- linewrapRadioFalse ,
480
+ wordwrapRadioTrue ,
481
+ wordwrapRadioFalse ,
484
482
props . setLinewrap ,
485
483
false
486
484
) ;
@@ -513,7 +511,7 @@ describe('<Preferences />', () => {
513
511
} ) ;
514
512
515
513
const generalElement1 = screen . getByRole ( 'radio' , {
516
- name : / l i n e w r a p o n / i
514
+ name : / w o r d w r a p o n / i
517
515
} ) ;
518
516
expect ( generalElement1 ) . toBeInTheDocument ( ) ;
519
517
} ) ;
0 commit comments