Skip to content

Commit

Permalink
Import BrowserInterface from next-webdriverq
Browse files Browse the repository at this point in the history
The lib path is private-ish while `next-webdriver` is a public module
  • Loading branch information
eps1lon committed Apr 8, 2024
1 parent e89f319 commit e8a201e
Show file tree
Hide file tree
Showing 11 changed files with 11 additions and 17 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { type BrowserInterface } from 'test/lib/browsers/base'
import { type BrowserInterface } from 'next-webdriver'
import { createNextDescribe } from 'e2e-utils'
import { check } from 'next-test-utils'

Expand Down
3 changes: 1 addition & 2 deletions test/development/basic/tailwind-jit.test.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { join } from 'path'
import webdriver from 'next-webdriver'
import webdriver, { BrowserInterface } from 'next-webdriver'
import { FileRef, nextTestSetup } from 'e2e-utils'
import { check, shouldRunTurboDevTest } from 'next-test-utils'
import { BrowserInterface } from 'test/lib/browsers/base'

// [TODO]: It is unclear why turbopack takes longer to run this test
// remove once it's fixed
Expand Down
3 changes: 1 addition & 2 deletions test/development/client-dev-overlay/index.test.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { createNext, FileRef } from 'e2e-utils'
import webdriver from 'next-webdriver'
import webdriver, { BrowserInterface } from 'next-webdriver'
import { NextInstance } from 'e2e-utils'
import { join } from 'path'
import { BrowserInterface } from 'test/lib/browsers/base'
import { check } from 'next-test-utils'

describe('client-dev-overlay', () => {
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/app-dir/app-a11y/index.test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { createNextDescribe } from 'e2e-utils'
import { check } from 'next-test-utils'
import type { BrowserInterface } from 'test/lib/browsers/base'
import type { BrowserInterface } from 'next-webdriver'

createNextDescribe(
'app a11y features',
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/app-dir/app-client-cache/client-cache.test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { createNextDescribe } from 'e2e-utils'
import { check } from 'next-test-utils'
import { BrowserInterface } from 'test/lib/browsers/base'
import { BrowserInterface } from 'next-webdriver'
import {
browserConfigWithFixedTime,
createRequestsListener,
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/app-dir/app-client-cache/test-utils.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { BrowserInterface } from 'test/lib/browsers/base'
import { BrowserInterface } from 'next-webdriver'
import type { Request } from 'playwright'

export const getPathname = (url: string) => {
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/app-dir/metadata/metadata.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { BrowserInterface } from 'test/lib/browsers/base'
import type { BrowserInterface } from 'next-webdriver'
import { createNextDescribe } from 'e2e-utils'
import { check } from 'next-test-utils'
import fs from 'fs/promises'
Expand Down
3 changes: 1 addition & 2 deletions test/e2e/ignore-invalid-popstateevent/with-i18n.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,9 @@ import { join } from 'path'
import { createNext, FileRef } from 'e2e-utils'
import { NextInstance } from 'e2e-utils'
import { check, waitFor } from 'next-test-utils'
import webdriver from 'next-webdriver'
import webdriver, { BrowserInterface } from 'next-webdriver'

import type { HistoryState } from '../../../packages/next/src/shared/lib/router/router'
import { BrowserInterface } from 'test/lib/browsers/base'

const emitPopsStateEvent = (browser: BrowserInterface, state: HistoryState) =>
browser.eval(
Expand Down
3 changes: 1 addition & 2 deletions test/e2e/ignore-invalid-popstateevent/without-i18n.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,9 @@ import { join } from 'path'
import { createNext, FileRef } from 'e2e-utils'
import { NextInstance } from 'e2e-utils'
import { check, waitFor } from 'next-test-utils'
import webdriver from 'next-webdriver'
import webdriver, { BrowserInterface } from 'next-webdriver'

import type { HistoryState } from '../../../packages/next/src/shared/lib/router/router'
import { BrowserInterface } from 'test/lib/browsers/base'

const emitPopsStateEvent = (browser: BrowserInterface, state: HistoryState) =>
browser.eval(
Expand Down
3 changes: 1 addition & 2 deletions test/e2e/next-script/index.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import webdriver from 'next-webdriver'
import webdriver, { BrowserInterface } from 'next-webdriver'
import { createNext } from 'e2e-utils'
import { NextInstance } from 'e2e-utils'
import { BrowserInterface } from 'test/lib/browsers/base'
import { check } from 'next-test-utils'

describe('beforeInteractive in document Head', () => {
Expand Down
3 changes: 1 addition & 2 deletions test/production/emit-decorator-metadata/index.test.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { join } from 'path'
import webdriver from 'next-webdriver'
import webdriver, { BrowserInterface } from 'next-webdriver'
import { createNext, FileRef } from 'e2e-utils'
import { NextInstance } from 'e2e-utils'
import { BrowserInterface } from 'test/lib/browsers/base'
import { fetchViaHTTP } from 'next-test-utils'

describe('emitDecoratorMetadata SWC option', () => {
Expand Down

0 comments on commit e8a201e

Please sign in to comment.