Fix special characters in failure detail📝FeedbackMar 22, 2024Fix the special characters in failure log detail2 comments1
Log in to comment and vote
Comments2
Amaranth Ox
Mar 22, 2024
@abigail_armijo Could you please share the script file you used.
Azure Breeze
Mar 26, 2024
Hello! is this: https://app.perfagents.ai/uncloud/dashboard/editor/65fbaf43cfe2798005bdad9a/sequence/ts/synthetic.spec.ts
import { expect, test } from '@playwright/test'; test.describe('Synthetic testing', () => { const baseURL = process.env.EFFIZIENTE_URL ? process.env.EFFIZIENTE_URL : 'https://effizientedemo.azurewebsites.net'; const baseAPIURL = process.env.EFFIZIENTE_API_URL ? process.env.EFFIZIENTE_API_URL : 'https://effizienteauthdemo.azurewebsites.net'; let token = ''; test.beforeEach(async ({ request }) => { const userLogin = { Company: process.env.EFFIZIENTE_COMPANY ?? 'Demo', UserName: process.env.EFFIZIENTE_ADMIN_USER ?? 'Demo', Password: process.env.EFFIZIENTE_ADMIN_PASSWORD ?? 'Demo', KeepSession: true, Code: 0 }; const loginAPi = baseAPIURL + '/api/Usuarios/Login'; const response = await request.post(loginAPi, { data: userLogin }); const responseBody = await response.json(); token = responseBody.Token; }); // eslint-disable-next-line playwright/expect-expect test('Should show dashboard', async ({ page }) => { const dashboardPageUrl = baseURL + '/AccountsReceivable/dashboard'; const stepDescription = 'Go to:' + baseURL; await test.step(stepDescription, async () => { test.info().annotations.push({ type: 'Navigation', description: stepDescription }); await page.goto(baseURL); await page.evaluate(token => { localStorage.setItem('token', token); }, token); }); await page.goto(dashboardPageUrl); await expect(page.locator('#top5 canvas')).toBeVisible({ timeout: 10_000 }); await expect(page.locator('#top5Debt canvas')).toBeVisible({ timeout: 10_000 }); await expect(page.locator('#top5DaysDelay canvas')).toBeVisible({ timeout: 10_000 }); await expect(page.locator('#summaryExpiration')).toBeVisible({ timeout: 10_000 }); const topMenuLocator = 'app-menu > p-menubar > .p-menubar > p-menubarsub > ul > li > .p-menuitem-content > a > .p-menuitem-text'; const menusInPage = await page.locator(topMenuLocator).allInnerTexts(); const menus = ['AccountsReceivable', 'Config']; await expect(menusInPage).toEqual(menus); }); });