@@ -2344,11 +2344,7 @@ describe('<CourseUnit />', () => {
23442344 expect ( screen . queryByText ( addComponentMessages . title . defaultMessage ) ) . not . toBeInTheDocument ( ) ;
23452345 } ) ;
23462346
2347- it ( 'renders new unit info/settings sidebar' , async ( ) => {
2348- setConfig ( {
2349- ...getConfig ( ) ,
2350- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2351- } ) ;
2347+ it ( 'renders unit info/settings sidebar' , async ( ) => {
23522348 const user = userEvent . setup ( ) ;
23532349 render ( < RootWrapper /> ) ;
23542350
@@ -2373,10 +2369,6 @@ describe('<CourseUnit />', () => {
23732369 } ) ;
23742370
23752371 it ( 'displays the live state in the status bar' , async ( ) => {
2376- setConfig ( {
2377- ...getConfig ( ) ,
2378- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2379- } ) ;
23802372 axiosMock
23812373 . onGet ( getCourseSectionVerticalApiUrl ( blockId ) )
23822374 . reply ( 200 , {
@@ -2473,11 +2465,6 @@ describe('<CourseUnit />', () => {
24732465 } ) ;
24742466
24752467 it ( 'displays the staff only state in the status bar' , async ( ) => {
2476- setConfig ( {
2477- ...getConfig ( ) ,
2478- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2479- } ) ;
2480-
24812468 axiosMock
24822469 . onGet ( getCourseSectionVerticalApiUrl ( blockId ) )
24832470 . reply ( 200 , {
@@ -2497,10 +2484,6 @@ describe('<CourseUnit />', () => {
24972484
24982485 it ( 'should disable discussions in the settings sidebar' , async ( ) => {
24992486 const user = userEvent . setup ( ) ;
2500- setConfig ( {
2501- ...getConfig ( ) ,
2502- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2503- } ) ;
25042487 render ( < RootWrapper /> ) ;
25052488
25062489 axiosMock
@@ -2553,11 +2536,6 @@ describe('<CourseUnit />', () => {
25532536
25542537 it ( 'should update the group access in the unit sidebar' , async ( ) => {
25552538 const user = userEvent . setup ( ) ;
2556-
2557- setConfig ( {
2558- ...getConfig ( ) ,
2559- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2560- } ) ;
25612539 render ( < RootWrapper /> ) ;
25622540
25632541 axiosMock
@@ -2633,10 +2611,6 @@ describe('<CourseUnit />', () => {
26332611 } ) ;
26342612
26352613 it ( 'should one group in the visibility field in the unit sidebar' , async ( ) => {
2636- setConfig ( {
2637- ...getConfig ( ) ,
2638- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2639- } ) ;
26402614 render ( < RootWrapper /> ) ;
26412615
26422616 axiosMock
@@ -2688,10 +2662,6 @@ describe('<CourseUnit />', () => {
26882662 } ) ;
26892663
26902664 it ( 'should multiple groups in the visibility field in the unit sidebar' , async ( ) => {
2691- setConfig ( {
2692- ...getConfig ( ) ,
2693- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2694- } ) ;
26952665 render ( < RootWrapper /> ) ;
26962666
26972667 axiosMock
@@ -2746,10 +2716,6 @@ describe('<CourseUnit />', () => {
27462716 } ) ;
27472717
27482718 it ( 'should render never published state in the unit sidebar' , async ( ) => {
2749- setConfig ( {
2750- ...getConfig ( ) ,
2751- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2752- } ) ;
27532719 render ( < RootWrapper /> ) ;
27542720
27552721 axiosMock
@@ -2776,10 +2742,6 @@ describe('<CourseUnit />', () => {
27762742 } ) ;
27772743
27782744 it ( 'displays the scheduled state in the status bar' , async ( ) => {
2779- setConfig ( {
2780- ...getConfig ( ) ,
2781- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2782- } ) ;
27832745 axiosMock
27842746 . onGet ( getCourseSectionVerticalApiUrl ( blockId ) )
27852747 . reply ( 200 , {
@@ -2796,10 +2758,6 @@ describe('<CourseUnit />', () => {
27962758 } ) ;
27972759
27982760 it ( 'displays the draft changes state in the status bar' , async ( ) => {
2799- setConfig ( {
2800- ...getConfig ( ) ,
2801- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2802- } ) ;
28032761 axiosMock
28042762 . onGet ( getCourseSectionVerticalApiUrl ( blockId ) )
28052763 . reply ( 200 , {
@@ -2816,10 +2774,6 @@ describe('<CourseUnit />', () => {
28162774 } ) ;
28172775
28182776 it ( 'displays discussions enabled label in the status bar' , async ( ) => {
2819- setConfig ( {
2820- ...getConfig ( ) ,
2821- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2822- } ) ;
28232777 axiosMock
28242778 . onGet ( getCourseSectionVerticalApiUrl ( blockId ) )
28252779 . reply ( 200 , {
@@ -2835,10 +2789,6 @@ describe('<CourseUnit />', () => {
28352789 } ) ;
28362790
28372791 it ( 'displays group access with one group in the status bar' , async ( ) => {
2838- setConfig ( {
2839- ...getConfig ( ) ,
2840- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2841- } ) ;
28422792 axiosMock
28432793 . onGet ( getCourseSectionVerticalApiUrl ( blockId ) )
28442794 . reply ( 200 , {
@@ -2882,10 +2832,6 @@ describe('<CourseUnit />', () => {
28822832 } ) ;
28832833
28842834 it ( 'displays group access with multiple groups in the status bar' , async ( ) => {
2885- setConfig ( {
2886- ...getConfig ( ) ,
2887- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2888- } ) ;
28892835 axiosMock
28902836 . onGet ( getCourseSectionVerticalApiUrl ( blockId ) )
28912837 . reply ( 200 , {
@@ -2932,7 +2878,6 @@ describe('<CourseUnit />', () => {
29322878 setConfig ( {
29332879 ...getConfig ( ) ,
29342880 ENABLE_TAGGING_TAXONOMY_PAGES : 'true' ,
2935- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
29362881 } ) ;
29372882
29382883 render ( < RootWrapper /> ) ;
@@ -2963,11 +2908,6 @@ describe('<CourseUnit />', () => {
29632908 } ;
29642909
29652910 beforeEach ( async ( ) => {
2966- setConfig ( {
2967- ...getConfig ( ) ,
2968- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
2969- } ) ;
2970-
29712911 // The Meilisearch client-side API uses fetch, not Axios.
29722912 fetchMock . mockReset ( ) ;
29732913 fetchMock . post ( searchEndpoint , ( _url , req ) => {
@@ -3211,10 +3151,6 @@ describe('<CourseUnit />', () => {
32113151 } ) ;
32123152
32133153 it ( 'not render add sidebar in units from libraries (read-only)' , async ( ) => {
3214- setConfig ( {
3215- ...getConfig ( ) ,
3216- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
3217- } ) ;
32183154 render ( < RootWrapper /> ) ;
32193155
32203156 axiosMock
@@ -3247,11 +3183,6 @@ describe('<CourseUnit />', () => {
32473183 } ) ;
32483184
32493185 it ( 'opens the component info sidebar on postMessage event' , async ( ) => {
3250- setConfig ( {
3251- ...getConfig ( ) ,
3252- ENABLE_UNIT_PAGE_NEW_DESIGN : 'true' ,
3253- } ) ;
3254-
32553186 render ( < RootWrapper /> ) ;
32563187
32573188 await screen . findByTitle ( xblockContainerIframeMessages . xblockIframeTitle . defaultMessage ) ;
0 commit comments