File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -278,13 +278,26 @@ describe('useSignStore', () => {
278278 it ( 'appends idDocApproval param when user is approver' , ( ) => {
279279 const store = useSignStore ( )
280280 store . document = createDocument ( {
281+ uuid : 'approver-file-uuid' ,
281282 settings : { isApprover : true } ,
282283 } )
283- const url = store . buildSignUrl ( 'some -uuid' , { documentId : 1 } )
284+ const url = store . buildSignUrl ( 'approver-file -uuid' , { documentId : 1 } )
284285
285286 expect ( url ) . toContain ( '&idDocApproval=true' )
286287 } )
287288
289+ it ( 'does not append idDocApproval param for approver signing as regular signer' , ( ) => {
290+ const store = useSignStore ( )
291+ store . document = createDocument ( {
292+ uuid : 'file-uuid' ,
293+ settings : { isApprover : true } ,
294+ } )
295+ const url = store . buildSignUrl ( 'sign-request-uuid' , { documentId : 1 } )
296+
297+ expect ( url ) . toContain ( '/sign/uuid/sign-request-uuid' )
298+ expect ( url ) . not . toContain ( 'idDocApproval' )
299+ } )
300+
288301 it ( 'does not append idDocApproval param when user is not approver' , ( ) => {
289302 const store = useSignStore ( )
290303 store . document = createDocument ( {
You can’t perform that action at this time.
0 commit comments