@@ -442,43 +442,44 @@ 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 } ) ;
449
-
450
- // get ahold of the radio buttons for toggling wordwrap
451
- const wordwrapRadioFalse = screen . getByRole ( 'radio' , {
445
+ // TODO: Consolidate "linewrap" (reference from backend/User model) and "word wrap" (currently used in UI) into consistent naming.
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' , {
452
453
name : / w o r d w r a p o f f / i
453
454
} ) ;
454
- const wordwrapRadioTrue = screen . getByRole ( 'radio' , {
455
+ const linewrapRadioTrue = screen . getByRole ( 'radio' , {
455
456
name : / w o r d w r a p o n / i
456
457
} ) ;
457
458
458
459
testToggle (
459
- wordwrapRadioFalse ,
460
- wordwrapRadioTrue ,
460
+ linewrapRadioFalse ,
461
+ linewrapRadioTrue ,
461
462
props . setLinewrap ,
462
463
true
463
464
) ;
464
465
} ) ;
465
466
} ) ;
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
+ describe ( 'start linewrap at true' , ( ) => {
468
+ it ( 'linewrap toggle, starting at true' , ( ) => {
469
+ // render the component with linewrap prop set to true
470
+ subject ( { linewrap : true } ) ;
470
471
471
- // get ahold of the radio buttons for toggling wordwrap
472
- const wordwrapRadioFalse = screen . getByRole ( 'radio' , {
472
+ // get ahold of the radio buttons for toggling linewrap
473
+ const linewrapRadioFalse = screen . getByRole ( 'radio' , {
473
474
name : / w o r d w r a p o f f / i
474
475
} ) ;
475
- const wordwrapRadioTrue = screen . getByRole ( 'radio' , {
476
+ const linewrapRadioTrue = screen . getByRole ( 'radio' , {
476
477
name : / w o r d w r a p o n / i
477
478
} ) ;
478
479
479
480
testToggle (
480
- wordwrapRadioTrue ,
481
- wordwrapRadioFalse ,
481
+ linewrapRadioTrue ,
482
+ linewrapRadioFalse ,
482
483
props . setLinewrap ,
483
484
false
484
485
) ;
0 commit comments