-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
46 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import { test, expect } from '@playwright/test'; | ||
|
||
test.describe('specific viewport block', () => { | ||
test.slow(); | ||
test.use({ viewport: { width: 1600, height: 1200 } }); | ||
|
||
test('has title', async ({ page }) => { | ||
await page.goto('/genes/comparison?category=Protein+-+Differential+Expression'); | ||
|
||
// wait for page to load (i.e. spinner to disappear) | ||
await expect(page.locator('div:nth-child(4) > div > .spinner')) | ||
.not.toBeVisible({ timeout: 250000}); | ||
|
||
// Expect a title "to contain" a substring. | ||
await expect(page).toHaveTitle('Gene Comparison | Visual comparison tool for AD genes'); | ||
}); | ||
|
||
test('sub-category is SRM by default', async ({ page }) => { | ||
test.slow(); | ||
// set category for Protein - Differential Expression | ||
await page.goto('/genes/comparison?category=Protein+-+Differential+Expression'); | ||
|
||
// wait for page to load (i.e. spinner to disappear) | ||
await expect(page.locator('div:nth-child(4) > div > .spinner')) | ||
.not.toBeVisible({ timeout: 150000}); | ||
|
||
// expect sub-category dropdown to be SRM | ||
const dropdown = await page.locator('#subCategory'); | ||
await expect(dropdown).toHaveText('Targeted Selected Reaction Monitoring (SRM)'); | ||
}); | ||
}); |