Skip to content

Commit

Permalink
chore(tests): removing all of vitest from AI Lab tests
Browse files Browse the repository at this point in the history
Signed-off-by: Tibor Dancs <[email protected]>
  • Loading branch information
ScrewTSW committed Sep 2, 2024
1 parent dd95fa1 commit b1554b4
Showing 1 changed file with 10 additions and 13 deletions.
23 changes: 10 additions & 13 deletions tests/playwright/src/ai-lab-extension.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,8 @@
***********************************************************************/

import type { Page } from '@playwright/test';
import { expect as playExpect } from '@playwright/test';
import { afterAll, beforeAll, beforeEach, describe, test } from 'vitest';
import type { DashboardPage, ExtensionsPage, RunnerTestContext } from '@podman-desktop/tests-playwright';
import { expect as playExpect, test } from '@playwright/test';
import type { DashboardPage, ExtensionsPage } from '@podman-desktop/tests-playwright';
import {
NavigationBar,
WelcomePage,
Expand Down Expand Up @@ -49,7 +48,7 @@ let navigationBar: NavigationBar;
let dashboardPage: DashboardPage;
let extensionsPage: ExtensionsPage;

beforeAll(async () => {
test.beforeAll(async () => {
pdRunner = new PodmanDesktopRunner({ customFolder: 'ai-lab-tests-pd', autoUpdate: false, autoCheckUpdate: false });
page = await pdRunner.start();
pdRunner.setVideoAndTraceName('ai-lab-e2e');
Expand All @@ -60,16 +59,12 @@ beforeAll(async () => {
await pdRunner.screenshot('ai-lab-tests-dashboard-podman-machine.png');
});

beforeEach<RunnerTestContext>(async ctx => {
ctx.pdRunner = pdRunner;
});

afterAll(async () => {
test.afterAll(async () => {
await pdRunner.close();
});

describe(`AI Lab extension installation and verification`, async () => {
describe(`AI Lab extension installation`, async () => {
test.describe.serial(`AI Lab extension installation and verification`, () => {
test.describe.serial(`AI Lab extension installation`, () => {
test(`Open Settings -> Extensions page`, async () => {
dashboardPage = await navigationBar.openDashboard();
await playExpect(dashboardPage.mainPage).toBeVisible();
Expand All @@ -90,12 +85,14 @@ describe(`AI Lab extension installation and verification`, async () => {
await aiLabPage.waitForLoad();
});
});
describe.skipIf(isLinux)(`AI Lab extension verification`, async () => {
test.describe.serial(`AI Lab extension verification`, () => {
test.skip(isLinux, `Skipping AI App deployment on Linux`);
test(`Open Recipes Catalog`, async () => {
recipesCatalogPage = await aiLabPage.navigationBar.openRecipesCatalog();
await recipesCatalogPage.waitForLoad();
});
test(`Install ChatBot example app`, { timeout: 780_000 }, async () => {
test(`Install ChatBot example app`, async () => {
test.setTimeout(780_000);
const chatBotApp: AILabAppDetailsPage = await recipesCatalogPage.openRecipesCatalogApp(
recipesCatalogPage.recipesCatalogNaturalLanguageProcessing,
AI_LAB_AI_APP_NAME,
Expand Down

0 comments on commit b1554b4

Please sign in to comment.