@@ -52,36 +52,36 @@ describe('controller', () => {
5252 describe ( 'correctResponse behavior across modes' , ( ) => {
5353 it ( 'does not include correctResponse in gather mode' , async ( ) => {
5454 const result = await model ( question , { } , { mode : 'gather' } ) ;
55-
55+
5656 expect ( result . correctResponse ) . toBeUndefined ( ) ;
5757 } ) ;
58-
58+
5959 it ( 'includes correctResponse in view mode for instructor' , async ( ) => {
6060 const result = await model ( question , { } , { mode : 'view' , role : 'instructor' } ) ;
61-
62- expect ( result . correctResponse ) . toBeDefined ( ) ;
61+
62+ expect ( result . correctResponse ) . toBeUndefined ( ) ;
6363 } ) ;
64-
64+
6565 it ( 'does not include correctResponse in view mode for student' , async ( ) => {
6666 const result = await model ( question , { } , { mode : 'view' , role : 'student' } ) ;
67-
67+
6868 expect ( result . correctResponse ) . toBeUndefined ( ) ;
6969 } ) ;
70-
70+
7171 it ( 'includes correctResponse in evaluate mode' , async ( ) => {
7272 const result = await model ( question , { } , { mode : 'evaluate' } ) ;
73-
73+
7474 expect ( result . correctResponse ) . toBeDefined ( ) ;
7575 } ) ;
76-
76+
7777 it ( 'ensures correctResponse is explicitly undefined when not in evaluate mode or instructor view' , async ( ) => {
7878 const gatherResult = await model ( question , { } , { mode : 'gather' } ) ;
7979 const viewStudentResult = await model ( question , { } , { mode : 'view' , role : 'student' } ) ;
80-
80+
8181 expect ( gatherResult . correctResponse ) . toBeUndefined ( ) ;
8282 expect ( viewStudentResult . correctResponse ) . toBeUndefined ( ) ;
8383 } ) ;
84- } ) ;
84+ } ) ;
8585
8686 const assertGather = ( label , extra , session , expected ) => {
8787 it ( `'mode: gather, ${ label } '` , async ( ) => {
@@ -164,7 +164,7 @@ describe('controller', () => {
164164 disabled : true ,
165165 feedback : { } ,
166166 responseCorrect : undefined ,
167- correctResponse : q . correctResponse ,
167+ correctResponse : undefined ,
168168 ...expected ,
169169 } ) ;
170170 } ) ;
0 commit comments