Skip to content

Commit

Permalink
✨ Use @playwright/test instead of playwright-core in source code
Browse files Browse the repository at this point in the history
  • Loading branch information
akm committed Oct 31, 2023
1 parent 136eec8 commit 8d4d0a8
Show file tree
Hide file tree
Showing 13 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion src/helpers/playwright/LocatorPredicate.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator} from 'playwright-core';
import {Locator} from '@playwright/test';

export type LocatorPredicate = (l: Locator) => Promise<boolean>;

Expand Down
2 changes: 1 addition & 1 deletion src/helpers/playwright/locator_attr.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator} from 'playwright-core';
import {Locator} from '@playwright/test';

export const hasDisabledAttr = async (l: Locator): Promise<boolean> => {
return l.evaluate((el: SVGElement | HTMLElement): boolean => {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/playwright/locator_utils.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Frame, Page, Locator} from 'playwright-core';
import {Frame, Page, Locator} from '@playwright/test';
import {isFrame, isPage} from './type_guards';

// See https://github.com/microsoft/playwright/blob/v1.14.1/src/client/locator.ts
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/playwright/pwRetry.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator, Page} from 'playwright-core';
import {Locator, Page} from '@playwright/test';
import {config} from '../config';

import {retry, retryAttempts} from '../retry';
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/playwright/sleepFunc.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Frame, Locator, Page} from 'playwright-core';
import {Frame, Locator, Page} from '@playwright/test';
import {getFrame} from './locator_utils';

export const sleepFunc = (
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/playwright/type_guards.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Frame, Page, Locator} from 'playwright-core';
import {Frame, Page, Locator} from '@playwright/test';

export const isFrame = (x: unknown): x is Frame => {
if (typeof x !== 'object' || x === null) return false;
Expand Down
2 changes: 1 addition & 1 deletion src/materials/Clickable.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator} from 'playwright-core';
import {Locator} from '@playwright/test';

import {RetryOptions, LocatorPredicate} from '../helpers/playwright';

Expand Down
2 changes: 1 addition & 1 deletion src/materials/Displayable.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator} from 'playwright-core';
import {Locator} from '@playwright/test';

export class Displayable {
constructor(readonly locator: Locator) {}
Expand Down
2 changes: 1 addition & 1 deletion src/materials/InputText.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator} from 'playwright-core';
import {Locator} from '@playwright/test';
import {pwRetryUi, RetryOptions} from '../helpers/playwright';

import {Operable, OperableOptions} from './Operable';
Expand Down
2 changes: 1 addition & 1 deletion src/materials/Operable.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator} from 'playwright-core';
import {Locator} from '@playwright/test';

import {
LocatorPredicate,
Expand Down
2 changes: 1 addition & 1 deletion src/materials/RadioButtons.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator, Page} from 'playwright-core';
import {Locator, Page} from '@playwright/test';
import {Selectable, SelectableOptions} from './Selectable';

export type SelectableArgs = string | [string, SelectableOptions?];
Expand Down
2 changes: 1 addition & 1 deletion src/materials/SelectTag.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator} from 'playwright-core';
import {Locator} from '@playwright/test';
import {Clickable, ClickableOptions} from './Clickable';
import {pwRetry} from '../helpers/playwright';

Expand Down
2 changes: 1 addition & 1 deletion src/materials/Selectable.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Locator} from 'playwright-core';
import {Locator} from '@playwright/test';

import {
LocatorPredicate,
Expand Down

0 comments on commit 8d4d0a8

Please sign in to comment.