diff --git a/tests/sanity/tests/model/recruiting/common-recruiting-page.ts b/tests/sanity/tests/model/recruiting/common-recruiting-page.ts index a0c92fcaea..efc3ef9848 100644 --- a/tests/sanity/tests/model/recruiting/common-recruiting-page.ts +++ b/tests/sanity/tests/model/recruiting/common-recruiting-page.ts @@ -29,7 +29,7 @@ export class CommonRecruitingPage extends CalendarPage { this.buttonSendComment = page.locator('g#Send') this.textComment = page.locator('div.showMore-content p') this.inputAddAttachment = page.locator('div.antiSection #file') - this.textAttachmentName = page.locator('div.name a') + this.textAttachmentName = page.locator('div.attachment-container > a') this.buttonCreateFirstReview = page.locator('span:has-text("Create review")') this.buttonMoreActions = page.locator('.popupPanel-title > .flex-row-center > button >> nth=0') this.buttonDelete = page.locator('button[class*="menuItem"] span', { hasText: 'Delete' }) diff --git a/tests/sanity/tests/model/recruiting/talent-details-page.ts b/tests/sanity/tests/model/recruiting/talent-details-page.ts index ac691e070a..30897ca37c 100644 --- a/tests/sanity/tests/model/recruiting/talent-details-page.ts +++ b/tests/sanity/tests/model/recruiting/talent-details-page.ts @@ -30,6 +30,7 @@ export class TalentDetailsPage extends CommonRecruitingPage { this.buttonPopupMergeContacts = page.locator('form[id="contact:string:MergePersons"] button > span', { hasText: 'Merge contacts' }) + this.textAttachmentName = page.locator('div.name a') } async addSkill (skillTag: string, skillDescription: string): Promise<void> { diff --git a/tests/sanity/tests/model/recruiting/vacancy-details-page.ts b/tests/sanity/tests/model/recruiting/vacancy-details-page.ts index 8fda3a20b9..4d1105ad23 100644 --- a/tests/sanity/tests/model/recruiting/vacancy-details-page.ts +++ b/tests/sanity/tests/model/recruiting/vacancy-details-page.ts @@ -33,7 +33,7 @@ export class VacancyDetailsPage extends CommonRecruitingPage { async addAttachments (filePath: string): Promise<void> { await this.inputAttachFile.setInputFiles(path.join(__dirname, `../../files/${filePath}`)) - await expect(this.textAttachmentName.filter({ hasText: filePath })).toBeVisible() + await expect(this.textAttachmentName).toHaveAttribute('download', filePath) } async addDescription (description: string): Promise<void> {