even if it looks file uploaded but it didn`t , can someone tell me how can i upload pdf file with cypress
cy.get("div.button").attachFile({ filePath:'form.pdf', mimeType:'application/pdf', encoding:"base64" }, {force:true, uploadType:"input"} )
even if it looks file uploaded but it didn`t , can someone tell me how can i upload pdf file with cypress
cy.get("div.button").attachFile({ filePath:'form.pdf', mimeType:'application/pdf', encoding:"base64" }, {force:true, uploadType:"input"} )
cy.get(div.button)
seems like you are targetting the wrong element. The correct element must be of type input
not type div
Take a close look at the HTML to find the correct selector
Upload a PDF