chore: rename common files to start with lower case

This commit is contained in:
Pavel Feldman 2019-12-12 20:54:40 -08:00
parent 5377f7a2d8
commit 5822de844a
16 changed files with 21 additions and 21 deletions

View file

@ -24,11 +24,11 @@ import * as URL from 'url';
import { Browser } from './Browser';
import { BrowserFetcher, BrowserFetcherOptions } from '../browserFetcher';
import { Connection } from './Connection';
import { TimeoutError } from '../Errors';
import { TimeoutError } from '../errors';
import { assert, debugError, helper } from '../helper';
import * as types from '../types';
import { PipeTransport } from './PipeTransport';
import { WebSocketTransport } from './WebSocketTransport';
import { WebSocketTransport } from '../webSocketTransport';
import { ConnectionTransport } from '../types';
import * as util from 'util';
import { launchProcess, waitForLine } from '../processLauncher';

View file

@ -18,8 +18,8 @@
import { Browser } from './Browser';
import { BrowserFetcher, BrowserFetcherOptions, BrowserFetcherRevisionInfo, OnProgressCallback } from '../browserFetcher';
import { ConnectionTransport } from '../types';
import { DeviceDescriptors, DeviceDescriptor } from '../DeviceDescriptors';
import * as Errors from '../Errors';
import { DeviceDescriptors, DeviceDescriptor } from '../deviceDescriptors';
import * as Errors from '../errors';
import { Launcher, LauncherBrowserOptions, LauncherChromeArgOptions, LauncherLaunchOptions, createBrowserFetcher } from './Launcher';
type Devices = { [name: string]: DeviceDescriptor } & DeviceDescriptor[];

View file

@ -4,7 +4,7 @@
export { ConsoleMessage } from '../console';
export { Dialog } from '../dialog';
export { ElementHandle } from '../dom';
export { TimeoutError } from '../Errors';
export { TimeoutError } from '../errors';
export { Frame } from '../frames';
export { Keyboard, Mouse } from '../input';
export { ExecutionContext, JSHandle } from '../javascript';

View file

@ -23,7 +23,7 @@ import {BrowserFetcher, BrowserFetcherOptions} from '../browserFetcher';
import * as fs from 'fs';
import * as util from 'util';
import {debugError, assert} from '../helper';
import {TimeoutError} from '../Errors';
import {TimeoutError} from '../errors';
import {WebSocketTransport} from './WebSocketTransport';
import { launchProcess, waitForLine } from '../processLauncher';

View file

@ -17,8 +17,8 @@
import { Browser } from './Browser';
import { BrowserFetcher, BrowserFetcherOptions, OnProgressCallback, BrowserFetcherRevisionInfo } from '../browserFetcher';
import { ConnectionTransport } from '../types';
import { DeviceDescriptors, DeviceDescriptor } from '../DeviceDescriptors';
import * as Errors from '../Errors';
import { DeviceDescriptors, DeviceDescriptor } from '../deviceDescriptors';
import * as Errors from '../errors';
import { Launcher, createBrowserFetcher } from './Launcher';
type Devices = { [name: string]: DeviceDescriptor } & DeviceDescriptor[];

View file

@ -1,7 +1,7 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
export { TimeoutError } from '../Errors';
export { TimeoutError } from '../errors';
export { Keyboard, Mouse } from '../input';
export { Browser } from './Browser';
export { BrowserContext } from '../browserContext';

View file

@ -22,7 +22,7 @@ import * as dom from './dom';
import * as network from './network';
import { helper, assert, RegisteredListener } from './helper';
import { ClickOptions, MultiClickOptions, PointerActionOptions, SelectOption } from './input';
import { TimeoutError } from './Errors';
import { TimeoutError } from './errors';
import { Events } from './events';
import { Page } from './page';
import { ConsoleMessage } from './console';

View file

@ -16,7 +16,7 @@
*/
import * as debug from 'debug';
import { TimeoutError } from './Errors';
import { TimeoutError } from './errors';
export const debugError = debug(`playwright:error`);

View file

@ -5,7 +5,7 @@ import * as fs from 'fs';
import * as path from 'path';
import { assert, helper } from './helper';
import * as types from './types';
import * as keyboardLayout from './USKeyboardLayout';
import * as keyboardLayout from './usKeyboardLayout';
const readFileAsync = helper.promisify(fs.readFile);

View file

@ -23,7 +23,7 @@ import * as input from './input';
import * as js from './javascript';
import * as network from './network';
import { Screenshotter } from './screenshotter';
import { TimeoutSettings } from './TimeoutSettings';
import { TimeoutSettings } from './timeoutSettings';
import * as types from './types';
import { Events } from './events';
import { BrowserContext, BrowserInterface } from './browserContext';

View file

@ -20,7 +20,7 @@ import * as stream from 'stream';
import * as removeFolder from 'rimraf';
import { helper } from './helper';
import * as readline from 'readline';
import { TimeoutError } from './Errors';
import { TimeoutError } from './errors';
const removeFolderAsync = helper.promisify(removeFolder);

View file

@ -16,7 +16,7 @@
*/
import * as WebSocket from 'ws';
import { ConnectionTransport } from '../types';
import { ConnectionTransport } from './types';
export class WebSocketTransport implements ConnectionTransport {
private _ws: WebSocket;

View file

@ -17,7 +17,7 @@
import * as input from '../input';
import { helper } from '../helper';
import { macEditingCommands } from '../USKeyboardLayout';
import { macEditingCommands } from '../usKeyboardLayout';
import { TargetSession } from './Connection';
function toModifiersMask(modifiers: Set<input.Modifier>): number {

View file

@ -16,8 +16,8 @@
*/
import { Browser } from './Browser';
import { BrowserFetcher, BrowserFetcherOptions, OnProgressCallback, BrowserFetcherRevisionInfo } from '../browserFetcher';
import { DeviceDescriptors } from '../DeviceDescriptors';
import * as Errors from '../Errors';
import { DeviceDescriptors } from '../deviceDescriptors';
import * as Errors from '../errors';
import { Launcher, LauncherLaunchOptions, createBrowserFetcher } from './Launcher';
export class Playwright {

View file

@ -1,7 +1,7 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
export { TimeoutError } from '../Errors';
export { TimeoutError } from '../errors';
export { Browser } from './Browser';
export { BrowserContext } from '../browserContext';
export { BrowserFetcher } from '../browserFetcher';

View file

@ -116,11 +116,11 @@ module.exports.addTests = function({testRunner, expect, defaultBrowserOptions, p
describe('Top-level requires', function() {
it('should require top-level Errors', async() => {
const Errors = require(path.join(utils.projectRoot(), '/Errors'));
const Errors = require(path.join(utils.projectRoot(), '/errors'));
expect(Errors.TimeoutError).toBe(playwright.errors.TimeoutError);
});
it('should require top-level DeviceDescriptors', async() => {
const Devices = require(path.join(utils.projectRoot(), '/DeviceDescriptors'));
const Devices = require(path.join(utils.projectRoot(), '/deviceDescriptors'));
expect(Devices['iPhone 6']).toBe(playwright.devices['iPhone 6']);
});
});