mirror of
https://github.com/Kong/insomnia
synced 2024-11-08 06:39:48 +00:00
5bba2e9545
* Initial exploration multiple test projects * Replace duplicate scenario with one to be filled in * Simplify number of playwright project configs * Fix testMatch setting on playwright config * Edit github actions to distinguish between CI and Release runs
20 lines
759 B
TypeScript
20 lines
759 B
TypeScript
import { expect } from '@playwright/test';
|
|
|
|
import { test } from '../../playwright/test';
|
|
|
|
test('can render Spectral OpenAPI lint errors', async ({ page }) => {
|
|
await page.click('text=Design');
|
|
await page.click('text=start from an example');
|
|
|
|
const codeEditor = page.locator('.pane-one');
|
|
await expect(codeEditor).toContainText('openapi: 3.0.0');
|
|
const specPreview = page.locator('.information-container');
|
|
await expect(specPreview).toContainText('This is a sample server Petstore server');
|
|
|
|
// Cause a lint error
|
|
await page.locator('[data-testid="CodeEditor"] >> text=info').click();
|
|
await page.locator('textarea').nth(1).press('Tab');
|
|
|
|
await expect(codeEditor).toContainText('oas3-schema Object must have required property "info"');
|
|
});
|