chore: move firefox to src/server/firefox (#3590)
This commit is contained in:
parent
6a53b205e5
commit
847201b132
|
|
@ -7,7 +7,7 @@ lib/
|
|||
*.js
|
||||
src/generated/*
|
||||
src/server/chromium/protocol.ts
|
||||
src/firefox/protocol.ts
|
||||
src/server/firefox/protocol.ts
|
||||
src/server/webkit/protocol.ts
|
||||
/types/*
|
||||
/index.d.ts
|
||||
|
|
|
|||
|
|
@ -15,11 +15,11 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import * as accessibility from '../accessibility';
|
||||
import * as accessibility from '../../accessibility';
|
||||
import { FFSession } from './ffConnection';
|
||||
import { Protocol } from './protocol';
|
||||
import * as dom from '../dom';
|
||||
import * as types from '../types';
|
||||
import * as dom from '../../dom';
|
||||
import * as types from '../../types';
|
||||
|
||||
export async function getAccessibilityTree(session: FFSession, needle?: dom.ElementHandle): Promise<{tree: accessibility.AXNode, needle: accessibility.AXNode | null}> {
|
||||
const objectId = needle ? needle._objectId : undefined;
|
||||
|
|
@ -15,14 +15,14 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Browser, BrowserOptions } from '../browser';
|
||||
import { assertBrowserContextIsNotOwned, BrowserContext, validateBrowserContextOptions, verifyGeolocation } from '../browserContext';
|
||||
import { helper, RegisteredListener } from '../helper';
|
||||
import { assert } from '../utils/utils';
|
||||
import * as network from '../network';
|
||||
import { Page, PageBinding } from '../page';
|
||||
import { ConnectionTransport } from '../transport';
|
||||
import * as types from '../types';
|
||||
import { Browser, BrowserOptions } from '../../browser';
|
||||
import { assertBrowserContextIsNotOwned, BrowserContext, validateBrowserContextOptions, verifyGeolocation } from '../../browserContext';
|
||||
import { helper, RegisteredListener } from '../../helper';
|
||||
import { assert } from '../../utils/utils';
|
||||
import * as network from '../../network';
|
||||
import { Page, PageBinding } from '../../page';
|
||||
import { ConnectionTransport } from '../../transport';
|
||||
import * as types from '../../types';
|
||||
import { ConnectionEvents, FFConnection } from './ffConnection';
|
||||
import { FFPage } from './ffPage';
|
||||
import { Protocol } from './protocol';
|
||||
|
|
@ -16,11 +16,11 @@
|
|||
*/
|
||||
|
||||
import { EventEmitter } from 'events';
|
||||
import { assert } from '../utils/utils';
|
||||
import { ConnectionTransport, ProtocolRequest, ProtocolResponse } from '../transport';
|
||||
import { assert } from '../../utils/utils';
|
||||
import { ConnectionTransport, ProtocolRequest, ProtocolResponse } from '../../transport';
|
||||
import { Protocol } from './protocol';
|
||||
import { rewriteErrorMessage } from '../utils/stackTrace';
|
||||
import { debugLogger } from '../utils/debugLogger';
|
||||
import { rewriteErrorMessage } from '../../utils/stackTrace';
|
||||
import { debugLogger } from '../../utils/debugLogger';
|
||||
|
||||
export const ConnectionEvents = {
|
||||
Disconnected: Symbol('Disconnected'),
|
||||
|
|
@ -15,12 +15,12 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import * as js from '../javascript';
|
||||
import * as js from '../../javascript';
|
||||
import { FFSession } from './ffConnection';
|
||||
import { Protocol } from './protocol';
|
||||
import * as sourceMap from '../utils/sourceMap';
|
||||
import { rewriteErrorMessage } from '../utils/stackTrace';
|
||||
import { parseEvaluationResultValue } from '../common/utilityScriptSerializers';
|
||||
import * as sourceMap from '../../utils/sourceMap';
|
||||
import { rewriteErrorMessage } from '../../utils/stackTrace';
|
||||
import { parseEvaluationResultValue } from '../../common/utilityScriptSerializers';
|
||||
|
||||
export class FFExecutionContext implements js.ExecutionContextDelegate {
|
||||
_session: FFSession;
|
||||
|
|
@ -15,8 +15,8 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import * as input from '../input';
|
||||
import * as types from '../types';
|
||||
import * as input from '../../input';
|
||||
import * as types from '../../types';
|
||||
import { FFSession } from './ffConnection';
|
||||
|
||||
function toModifiersMask(modifiers: Set<types.KeyboardModifier>): number {
|
||||
|
|
@ -15,12 +15,12 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { helper, RegisteredListener } from '../helper';
|
||||
import { helper, RegisteredListener } from '../../helper';
|
||||
import { FFSession } from './ffConnection';
|
||||
import { Page } from '../page';
|
||||
import * as network from '../network';
|
||||
import * as frames from '../frames';
|
||||
import * as types from '../types';
|
||||
import { Page } from '../../page';
|
||||
import * as network from '../../network';
|
||||
import * as frames from '../../frames';
|
||||
import * as types from '../../types';
|
||||
import { Protocol } from './protocol';
|
||||
|
||||
export class FFNetworkManager {
|
||||
|
|
@ -15,14 +15,14 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import * as dialog from '../dialog';
|
||||
import * as dom from '../dom';
|
||||
import * as frames from '../frames';
|
||||
import { helper, RegisteredListener } from '../helper';
|
||||
import { assert } from '../utils/utils';
|
||||
import { Page, PageBinding, PageDelegate, Worker } from '../page';
|
||||
import { kScreenshotDuringNavigationError } from '../screenshotter';
|
||||
import * as types from '../types';
|
||||
import * as dialog from '../../dialog';
|
||||
import * as dom from '../../dom';
|
||||
import * as frames from '../../frames';
|
||||
import { helper, RegisteredListener } from '../../helper';
|
||||
import { assert } from '../../utils/utils';
|
||||
import { Page, PageBinding, PageDelegate, Worker } from '../../page';
|
||||
import { kScreenshotDuringNavigationError } from '../../screenshotter';
|
||||
import * as types from '../../types';
|
||||
import { getAccessibilityTree } from './ffAccessibility';
|
||||
import { FFBrowserContext } from './ffBrowser';
|
||||
import { FFSession, FFSessionEvents } from './ffConnection';
|
||||
|
|
@ -30,9 +30,9 @@ import { FFExecutionContext } from './ffExecutionContext';
|
|||
import { RawKeyboardImpl, RawMouseImpl } from './ffInput';
|
||||
import { FFNetworkManager } from './ffNetworkManager';
|
||||
import { Protocol } from './protocol';
|
||||
import { selectors } from '../selectors';
|
||||
import { rewriteErrorMessage } from '../utils/stackTrace';
|
||||
import { Screencast, BrowserContext } from '../browserContext';
|
||||
import { selectors } from '../../selectors';
|
||||
import { rewriteErrorMessage } from '../../utils/stackTrace';
|
||||
import { Screencast, BrowserContext } from '../../browserContext';
|
||||
|
||||
const UTILITY_WORLD_NAME = '__playwright_utility_world__';
|
||||
|
||||
|
|
@ -18,14 +18,14 @@
|
|||
import * as os from 'os';
|
||||
import * as fs from 'fs';
|
||||
import * as path from 'path';
|
||||
import { FFBrowser } from '../firefox/ffBrowser';
|
||||
import { kBrowserCloseMessageId } from '../firefox/ffConnection';
|
||||
import { BrowserTypeBase } from './browserType';
|
||||
import { Env } from './processLauncher';
|
||||
import { ConnectionTransport } from '../transport';
|
||||
import { BrowserOptions } from '../browser';
|
||||
import { BrowserDescriptor } from '../utils/browserPaths';
|
||||
import * as types from '../types';
|
||||
import { FFBrowser } from './ffBrowser';
|
||||
import { kBrowserCloseMessageId } from './ffConnection';
|
||||
import { BrowserTypeBase } from '../browserType';
|
||||
import { Env } from '../processLauncher';
|
||||
import { ConnectionTransport } from '../../transport';
|
||||
import { BrowserOptions } from '../../browser';
|
||||
import { BrowserDescriptor } from '../../utils/browserPaths';
|
||||
import * as types from '../../types';
|
||||
|
||||
export class Firefox extends BrowserTypeBase {
|
||||
constructor(packagePath: string, browser: BrowserDescriptor) {
|
||||
|
|
@ -16,7 +16,7 @@
|
|||
|
||||
import { Chromium } from './chromium/chromium';
|
||||
import { WebKit } from './webkit/webkit';
|
||||
import { Firefox } from './firefox';
|
||||
import { Firefox } from './firefox/firefox';
|
||||
import { selectors } from '../selectors';
|
||||
import * as browserPaths from '../utils/browserPaths';
|
||||
|
||||
|
|
|
|||
|
|
@ -76,6 +76,7 @@ const DEPS = new Map([
|
|||
['src/install/', ['src/install/', 'src/utils/']],
|
||||
['src/server/chromium/', ['src/server/chromium/', 'src/utils/', 'src/', 'src/common/', 'src/server/']],
|
||||
['src/server/electron/', ['src/server/electron/', 'src/server/chromium/', 'src/utils/', 'src/', 'src/server/']],
|
||||
['src/server/firefox/', ['src/server/firefox/', 'src/utils/', 'src/', 'src/common/', 'src/server/']],
|
||||
['src/server/webkit/', ['src/server/webkit/', 'src/utils/', 'src/', 'src/common/', 'src/server/']],
|
||||
['src/client/', ['src/client/', 'src/utils/', 'src/protocol/', 'src/server/chromium/protocol.ts']],
|
||||
]);
|
||||
|
|
|
|||
Loading…
Reference in a new issue