Skip to content

Commit

Permalink
chore: migrate @protocol to @playwright/protocol
Browse files Browse the repository at this point in the history
  • Loading branch information
mxschmitt committed Dec 14, 2024
1 parent 91d4b82 commit 403214d
Show file tree
Hide file tree
Showing 124 changed files with 126 additions and 124 deletions.
7 changes: 7 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion packages/html-reporter/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
"baseUrl": ".",
"useUnknownInCatchVariables": false,
"paths": {
"@protocol/*": ["../protocol/src/*"],
"@web/*": ["../web/src/*"],
"@playwright/*": ["../playwright/src/*"],
"playwright-core/lib/*": ["../playwright-core/src/*"],
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/accessibility.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type { ElementHandle } from './elementHandle';
import type * as api from '../../types/types';

Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/android.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

import fs from 'fs';
import { isString, isRegExp, monotonicTime } from '../utils';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { Events } from './events';
import { BrowserContext, prepareBrowserContextParams } from './browserContext';
import { ChannelOwner } from './channelOwner';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/artifact.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import * as fs from 'fs';
import { Stream } from './stream';
import { mkdirIfNeeded } from '../utils/fileUtils';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/browser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import fs from 'fs';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { BrowserContext, prepareBrowserContextParams } from './browserContext';
import type { Page } from './page';
import { ChannelOwner } from './channelOwner';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/browserContext.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
import { Page, BindingCall } from './page';
import { Frame } from './frame';
import * as network from './network';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import fs from 'fs';
import path from 'path';
import { ChannelOwner } from './channelOwner';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/browserType.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { Browser } from './browser';
import { BrowserContext, prepareBrowserContextParams } from './browserContext';
import { ChannelOwner } from './channelOwner';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/cdpSession.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';
import type { Protocol } from '../server/chromium/protocol';
import type * as api from '../../types/types';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/channelOwner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import { EventEmitter } from './eventEmitter';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { maybeFindValidator, ValidationError, type ValidatorContext } from '../protocol/validator';
import { debugLogger } from '../utils/debugLogger';
import type { ExpectZone } from '../utils/stackTrace';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type { StackFrame } from '@protocol/channels';
import type { StackFrame } from '@playwright/protocol/src/channels';
import type { BrowserContext } from './browserContext';
import type { APIRequestContext } from './fetch';

Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/connection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import { parseError, TargetClosedError } from './errors';
import { CDPSession } from './cdpSession';
import { Playwright } from './playwright';
import { Electron, ElectronApplication } from './electron';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { Stream } from './stream';
import { WritableStream } from './writableStream';
import { debugLogger } from '../utils/debugLogger';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/consoleMessage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

import * as util from 'util';
import { JSHandle } from './jsHandle';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type * as api from '../../types/types';
import { Page } from './page';

Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/coverage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type * as api from '../../types/types';

export class Coverage implements api.Coverage {
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/dialog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';
import type * as api from '../../types/types';
import { Page } from './page';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/electron.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import type { BrowserWindow } from 'electron';
import type * as childProcess from 'child_process';
import type * as structs from '../../types/structs';
import type * as api from '../../types/types';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { TimeoutSettings } from '../common/timeoutSettings';
import { BrowserContext, prepareBrowserContextParams } from './browserContext';
import { ChannelOwner } from './channelOwner';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/elementHandle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { Frame } from './frame';
import type { Locator } from './locator';
import { JSHandle, serializeArgument, parseResult } from './jsHandle';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/errors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type { SerializedError } from '@protocol/channels';
import type { SerializedError } from '@playwright/protocol/src/channels';
import { isError } from '../utils';
import { parseSerializedValue, serializeValue } from '../protocol/serializers';

Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/fetch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import * as util from 'util';
import type { Serializable } from '../../types/structs';
import type * as api from '../../types/types';
import type { HeadersArray, NameValue } from '../common/types';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { assert, headersObjectToArray, isString } from '../utils';
import { mkdirIfNeeded } from '../utils/fileUtils';
import { ChannelOwner } from './channelOwner';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/fileChooser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import type { ElementHandle } from './elementHandle';
import type { Page } from './page';
import type { FilePayload } from './types';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type * as api from '../../types/types';

export class FileChooser implements api.FileChooser {
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/frame.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/

import { assert } from '../utils';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';
import { FrameLocator, Locator, testIdAttributeName } from './locator';
import type { LocatorOptions } from './locator';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type * as api from '../../types/types';
import type { Page } from './page';

Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/jsHandle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';
import { parseSerializedValue, serializeValue } from '../protocol/serializers';
import type * as api from '../../types/types';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/jsonPipe.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';

export class JsonPipe extends ChannelOwner<channels.JsonPipeChannel> {
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/localUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';
import type { Size } from './types';

Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/locator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

import type * as structs from '../../types/structs';
import type * as api from '../../types/types';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import * as util from 'util';
import { asLocator, isString, monotonicTime } from '../utils';
import { ElementHandle } from './elementHandle';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/network.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import { URLSearchParams } from 'url';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';
import { Frame } from './frame';
import { Worker } from './worker';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import type * as structs from '../../types/structs';
import type * as api from '../../types/types';
import { serializeError, isTargetClosedError, TargetClosedError } from './errors';
import { TimeoutSettings } from '../common/timeoutSettings';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { assert, headersObjectToArray, isObject, isRegExp, isString, LongStandingScope, urlMatches, urlMatchesEqual, mkdirIfNeeded, trimStringWithEllipsis, type URLMatch } from '../utils';
import { Accessibility } from './accessibility';
import { Artifact } from './artifact';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/playwright.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { TimeoutError } from './errors';
import { Android } from './android';
import { BrowserType } from './browserType';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/selectors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import { evaluationScript } from './clientHelper';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';
import type { SelectorEngine } from './types';
import type * as api from '../../types/types';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/stream.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import { Readable } from 'stream';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';

export class Stream extends ChannelOwner<channels.StreamChannel> {
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/tracing.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import type * as api from '../../types/types';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { Artifact } from './artifact';
import { ChannelOwner } from './channelOwner';

Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type { Size } from '../common/types';
export type { Size, Point, Rect, Quad, TimeoutOptions, HeadersArray } from '../common/types';

Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/waiter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import { rewriteErrorMessage } from '../utils/stackTrace';
import { TimeoutError } from './errors';
import { createGuid, zones } from '../utils';
import type { Zone } from '../utils';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type { ChannelOwner } from './channelOwner';

export class Waiter {
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/worker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import { Events } from './events';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';
import { assertMaxArguments, JSHandle, parseResult, serializeArgument } from './jsHandle';
import type { Page } from './page';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/client/writableStream.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import { Writable } from 'stream';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { ChannelOwner } from './channelOwner';

export class WritableStream extends ChannelOwner<channels.WritableStreamChannel> {
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/protocol/serializers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type { SerializedValue } from '@protocol/channels';
import type { SerializedValue } from '@playwright/protocol/src/channels';

export function parseSerializedValue(value: SerializedValue, handles: any[] | undefined): any {
return innerParseSerializedValue(value, handles, new Map());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

import type { WebSocket } from '../utilsBundle';
import type { DispatcherScope, Playwright } from '../server';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { createPlaywright, DispatcherConnection, RootDispatcher, PlaywrightDispatcher } from '../server';
import { Browser } from '../server/browser';
import { serverSideCallMetadata } from '../server/instrumentation';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/server/accessibility.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/

import type * as dom from './dom';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';

export interface AXNode {
isInteresting(insideControl: boolean): boolean;
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/server/android/android.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ import { PipeTransport } from '../../protocol/transport';
import { RecentLogsCollector } from '../../utils/debugLogger';
import { gracefullyCloseSet } from '../../utils/processLauncher';
import { TimeoutSettings } from '../../common/timeoutSettings';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import { SdkObject, serverSideCallMetadata } from '../instrumentation';
import { chromiumSwitches } from '../chromium/chromiumSwitches';
import { registry } from '../registry';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/server/android/backendAdb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import { debug } from '../../utilsBundle';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import * as net from 'net';
import { EventEmitter } from 'events';
import type { Backend, DeviceBackend, SocketBackend } from './android';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/server/bidi/bidiBrowser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type { RegisteredListener } from '../../utils/eventsHelper';
import { eventsHelper } from '../../utils/eventsHelper';
import type { BrowserOptions } from '../browser';
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright-core/src/server/bidi/bidiPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import * as dom from '../dom';
import * as dialog from '../dialog';
import type * as frames from '../frames';
import { Page } from '../page';
import type * as channels from '@protocol/channels';
import type * as channels from '@playwright/protocol/src/channels';
import type { InitScript, PageDelegate } from '../page';
import type { Progress } from '../progress';
import type * as types from '../types';
Expand Down
Loading

0 comments on commit 403214d

Please sign in to comment.