@@ -127,6 +127,9 @@ describe("<SmsMultiFactorEnrollmentForm />", () => {
127127 verificationCode : "Verification Code" ,
128128 verifyCode : "Verify Code" ,
129129 } ,
130+ prompts : {
131+ mfaSmsEnrollmentVerificationPrompt : "mfaSmsEnrollmentVerificationPrompt" ,
132+ } ,
130133 } ) ,
131134 } ) ;
132135
@@ -149,6 +152,10 @@ describe("<SmsMultiFactorEnrollmentForm />", () => {
149152 expect ( screen . getByTestId ( "input-otp" ) ) . toBeInTheDocument ( ) ;
150153 } ) ;
151154
155+ const description = container . querySelector ( '[data-slot="form-description"]' ) ;
156+ expect ( description ) . toBeInTheDocument ( ) ;
157+ expect ( description ) . toHaveTextContent ( "mfaSmsEnrollmentVerificationPrompt" ) ;
158+
152159 expect ( screen . getByRole ( "button" , { name : "Verify Code" } ) ) . toBeInTheDocument ( ) ;
153160 } ) ;
154161
@@ -196,6 +203,9 @@ describe("<SmsMultiFactorEnrollmentForm />", () => {
196203 verificationCode : "Verification Code" ,
197204 verifyCode : "Verify Code" ,
198205 } ,
206+ prompts : {
207+ mfaSmsEnrollmentVerificationPrompt : "mfaSmsEnrollmentVerificationPrompt" ,
208+ } ,
199209 } ) ,
200210 } ) ;
201211
@@ -206,7 +216,6 @@ describe("<SmsMultiFactorEnrollmentForm />", () => {
206216 } )
207217 ) ;
208218
209- // Fill in display name first
210219 const displayNameInput = container . querySelector ( "input[name='displayName']" ) ! ;
211220 fireEvent . change ( displayNameInput , { target : { value : "Test User" } } ) ;
212221
@@ -218,6 +227,10 @@ describe("<SmsMultiFactorEnrollmentForm />", () => {
218227 expect ( screen . getByTestId ( "input-otp" ) ) . toBeInTheDocument ( ) ;
219228 } ) ;
220229
230+ const description = container . querySelector ( '[data-slot="form-description"]' ) ;
231+ expect ( description ) . toBeInTheDocument ( ) ;
232+ expect ( description ) . toHaveTextContent ( "mfaSmsEnrollmentVerificationPrompt" ) ;
233+
221234 const verificationInput = screen . getByTestId ( "input-otp-slot-0" ) ;
222235 fireEvent . change ( verificationInput , { target : { value : "123456" } } ) ;
223236 fireEvent . click ( screen . getByRole ( "button" , { name : "Verify Code" } ) ) ;
@@ -239,6 +252,9 @@ describe("<SmsMultiFactorEnrollmentForm />", () => {
239252 verificationCode : "Verification Code" ,
240253 verifyCode : "Verify Code" ,
241254 } ,
255+ prompts : {
256+ mfaSmsEnrollmentVerificationPrompt : "mfaSmsEnrollmentVerificationPrompt" ,
257+ } ,
242258 } ) ,
243259 } ) ;
244260
@@ -249,7 +265,6 @@ describe("<SmsMultiFactorEnrollmentForm />", () => {
249265 } )
250266 ) ;
251267
252- // Fill in display name first
253268 const displayNameInput = container . querySelector ( "input[name='displayName']" ) ! ;
254269 fireEvent . change ( displayNameInput , { target : { value : "Test User" } } ) ;
255270
@@ -261,6 +276,10 @@ describe("<SmsMultiFactorEnrollmentForm />", () => {
261276 expect ( screen . getByTestId ( "input-otp" ) ) . toBeInTheDocument ( ) ;
262277 } ) ;
263278
279+ const description = container . querySelector ( '[data-slot="form-description"]' ) ;
280+ expect ( description ) . toBeInTheDocument ( ) ;
281+ expect ( description ) . toHaveTextContent ( "mfaSmsEnrollmentVerificationPrompt" ) ;
282+
264283 const verificationInput = screen . getByTestId ( "input-otp-slot-0" ) ;
265284 fireEvent . change ( verificationInput , { target : { value : "123456" } } ) ;
266285 fireEvent . click ( screen . getByRole ( "button" , { name : "Verify Code" } ) ) ;
0 commit comments