The Open Source DocuSign Alternative.
TypeScript digital-signaturedocument-signingdocusign-alternativee-signatureesignesignaturenext-authnextjsopen-sourcepades-standardpdfpdf-signpdf-signaturepostgresqlprismaself-hostedsigningtypescript
chore: update failing tests
Mythie3a57f972185e
diff --git a/packages/app-tests/e2e/document-auth/action-auth.spec.ts b/packages/app-tests/e2e/document-auth/action-auth.spec.tsindex ac69a6c22..5a29f287c 100644--- a/packages/app-tests/e2e/document-auth/action-auth.spec.ts+++ b/packages/app-tests/e2e/document-auth/action-auth.spec.ts@@ -49,8 +49,8 @@ test('[DOCUMENT_AUTH]: should allow signing when no auth setup', async ({ page }await page.locator(`#field-${field.id}`).getByRole('button').click();if (field.type === FieldType.TEXT) {- await page.getByLabel('Custom Text').fill('TEXT');- await page.getByRole('button', { name: 'Save Text' }).click();+ await page.locator('#custom-text').fill('TEXT');+ await page.getByRole('button', { name: 'Save' }).click();}await expect(page.locator(`#field-${field.id}`)).toHaveAttribute('data-inserted', 'true');@@ -109,8 +109,8 @@ test('[DOCUMENT_AUTH]: should allow signing with valid global auth', async ({ paawait page.locator(`#field-${field.id}`).getByRole('button').click();if (field.type === FieldType.TEXT) {- await page.getByLabel('Custom Text').fill('TEXT');- await page.getByRole('button', { name: 'Save Text' }).click();+ await page.locator('#custom-text').fill('TEXT');+ await page.getByRole('button', { name: 'Save' }).click();}await expect(page.locator(`#field-${field.id}`)).toHaveAttribute('data-inserted', 'true');@@ -287,8 +287,8 @@ test('[DOCUMENT_AUTH]: should allow field signing when required for recipient auawait page.locator(`#field-${field.id}`).getByRole('button').click();if (field.type === FieldType.TEXT) {- await page.getByLabel('Custom Text').fill('TEXT');- await page.getByRole('button', { name: 'Save Text' }).click();+ await page.locator('#custom-text').fill('TEXT');+ await page.getByRole('button', { name: 'Save' }).click();}await expect(page.locator(`#field-${field.id}`)).toHaveAttribute('data-inserted', 'true', {@@ -398,8 +398,8 @@ test('[DOCUMENT_AUTH]: should allow field signing when required for recipient anawait page.locator(`#field-${field.id}`).getByRole('button').click();if (field.type === FieldType.TEXT) {- await page.getByLabel('Custom Text').fill('TEXT');- await page.getByRole('button', { name: 'Save Text' }).click();+ await page.locator('#custom-text').fill('TEXT');+ await page.getByRole('button', { name: 'Save' }).click();}await expect(page.locator(`#field-${field.id}`)).toHaveAttribute('data-inserted', 'true', {diff --git a/packages/app-tests/e2e/document-flow/stepper-component.spec.ts b/packages/app-tests/e2e/document-flow/stepper-component.spec.tsindex 0a960c925..327e0ab74 100644--- a/packages/app-tests/e2e/document-flow/stepper-component.spec.ts+++ b/packages/app-tests/e2e/document-flow/stepper-component.spec.ts@@ -81,7 +81,7 @@ test('[DOCUMENT_FLOW]: should be able to create a document', async ({ page }) =>// Add fieldsawait expect(page.getByRole('heading', { name: 'Add Fields' })).toBeVisible();- await page.getByRole('button', { name: 'User 1 Signature' }).click();+ await page.getByRole('button', { name: 'Signature' }).click();await page.locator('canvas').click({position: {x: 100,@@ -89,7 +89,7 @@ test('[DOCUMENT_FLOW]: should be able to create a document', async ({ page }) =>},});- await page.getByRole('button', { name: 'Email Email' }).click();+ await page.getByRole('button', { name: 'Email' }).click();await page.locator('canvas').click({position: {x: 100,@@ -147,7 +147,7 @@ test('[DOCUMENT_FLOW]: should be able to create a document with multiple recipie// Add fieldsawait expect(page.getByRole('heading', { name: 'Add Fields' })).toBeVisible();- await page.getByRole('button', { name: 'User 1 Signature' }).click();+ await page.getByRole('button', { name: 'Signature' }).click();await page.locator('canvas').click({position: {x: 100,@@ -155,7 +155,7 @@ test('[DOCUMENT_FLOW]: should be able to create a document with multiple recipie},});- await page.getByRole('button', { name: 'Email Email' }).click();+ await page.getByRole('button', { name: 'Email' }).click();await page.locator('canvas').click({position: {x: 100,@@ -166,7 +166,7 @@ test('[DOCUMENT_FLOW]: should be able to create a document with multiple recipieawait page.getByText('User 1 ([email protected])').click();await page.getByText('User 2 ([email protected])').click();- await page.getByRole('button', { name: 'User 2 Signature' }).click();+ await page.getByRole('button', { name: 'Signature' }).click();await page.locator('canvas').click({position: {x: 500,@@ -174,7 +174,7 @@ test('[DOCUMENT_FLOW]: should be able to create a document with multiple recipie},});- await page.getByRole('button', { name: 'Email Email' }).click();+ await page.getByRole('button', { name: 'Email' }).click();await page.locator('canvas').click({position: {x: 500,@@ -243,7 +243,10 @@ test('[DOCUMENT_FLOW]: should be able to create a document with multiple recipie// Add fieldsawait expect(page.getByRole('heading', { name: 'Add Fields' })).toBeVisible();- await page.getByRole('button', { name: 'User 1 Signature' }).click();+ await page.locator('button[role="combobox"]').nth(0).click();+ await page.getByTitle('User 1 ([email protected])').click();++ await page.getByRole('button', { name: 'Signature' }).click();await page.locator('canvas').click({position: {x: 100,@@ -251,7 +254,7 @@ test('[DOCUMENT_FLOW]: should be able to create a document with multiple recipie},});- await page.getByRole('button', { name: 'Email Email' }).click();+ await page.getByRole('button', { name: 'Email' }).click();await page.locator('canvas').click({position: {x: 100,@@ -259,10 +262,10 @@ test('[DOCUMENT_FLOW]: should be able to create a document with multiple recipie},});- await page.getByText('User 1 ([email protected])').click();- await page.getByText('User 3 ([email protected])').click();+ await page.locator('button[role="combobox"]').nth(0).click();+ await page.getByTitle('User 3 ([email protected])').click();- await page.getByRole('button', { name: 'User 3 Signature' }).click();+ await page.getByRole('button', { name: 'Signature' }).click();await page.locator('canvas').click({position: {x: 500,@@ -270,7 +273,7 @@ test('[DOCUMENT_FLOW]: should be able to create a document with multiple recipie},});- await page.getByRole('button', { name: 'Email Email' }).click();+ await page.getByRole('button', { name: 'Email' }).click();await page.locator('canvas').click({position: {x: 500,@@ -465,7 +468,7 @@ test('[DOCUMENT_FLOW]: should be able to create, send with redirect url, sign atest('[DOCUMENT_FLOW]: should be able to sign a document with custom date', async ({ page }) => {const user = await seedUser();- const customDate = DateTime.local().toFormat('yyyy-MM-dd hh:mm a');+ const customDate = DateTime.utc().toFormat('yyyy-MM-dd hh:mm a');const { document, recipients } = await seedPendingDocumentWithFullFields({owner: user,