From 1a09035743954dfd40a1b0c8d2307cccfa94508e Mon Sep 17 00:00:00 2001 From: kreosus <59621250+kreosus@users.noreply.github.com> Date: Thu, 27 Oct 2022 12:04:45 -0500 Subject: [PATCH] INS-2087 Prelease Test for Plugins (#5337) Co-authored-by: Filipe Freire Co-authored-by: Filipe Freire --- .../prerelease/plugins-interactions.test.ts | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 packages/insomnia-smoke-test/tests/prerelease/plugins-interactions.test.ts diff --git a/packages/insomnia-smoke-test/tests/prerelease/plugins-interactions.test.ts b/packages/insomnia-smoke-test/tests/prerelease/plugins-interactions.test.ts new file mode 100644 index 0000000000..4a7c86faff --- /dev/null +++ b/packages/insomnia-smoke-test/tests/prerelease/plugins-interactions.test.ts @@ -0,0 +1,21 @@ +import { expect } from '@playwright/test'; + +import { test } from '../../playwright/test'; + +test.describe('Plugins', async () => { + test('Open plugins menu and generate plugin', async ({ page }) => { + // Opening settings + await page.locator('[data-testid="settings-button"]').click(); + // Switching to Plugins tab + await page.locator('li[role="tab"]:has-text("Plugins")').click(); + + // Generate new plugin + await page.locator('text=Generate New Plugin').click(); + await page.locator('text=Generate').first().click(); + + // check if the plugin shows up on the plugin list + await expect(page.locator('.app')).toContainText('insomnia-plugin-demo-example'); + }); + + // TODO: more scenarios will be added in follow-up iterations of increasing test coverage +});