prettier/tests/typescript_interface/__snapshots__/jsfmt.spec.js.snap

421 lines
10 KiB
Plaintext

// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`abstract.ts 1`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
| printWidth
=====================================input======================================
abstract interface I {
}
=====================================output=====================================
abstract interface I {}
================================================================================
`;
exports[`abstract.ts 2`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
abstract interface I {
}
=====================================output=====================================
abstract interface I {}
================================================================================
`;
exports[`comments.js 1`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
| printWidth
=====================================input======================================
interface ScreenObject {
// I make things weird.
at(point: Point): Screen | undefined;
}
=====================================output=====================================
interface ScreenObject {
// I make things weird.
at(point: Point): Screen | undefined;
}
================================================================================
`;
exports[`comments.js 2`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
interface ScreenObject {
// I make things weird.
at(point: Point): Screen | undefined;
}
=====================================output=====================================
interface ScreenObject {
// I make things weird.
at(point: Point): Screen | undefined
}
================================================================================
`;
exports[`ignore.js 1`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
| printWidth
=====================================input======================================
interface Interface {
// prettier-ignore
prop: type
// prettier-ignore
prop: type;
prop: type;
}
// Last element
interface Interface {
// prettier-ignore
prop: type
prop: type
}
interface foo extends bar {
// prettier-ignore
f(): void;
// prettier-ignore
g(): void;
h(): void;
}
interface T<T> {
// prettier-ignore
new<T>(): T<T>;
new<T>(): T<T>;
}
=====================================output=====================================
interface Interface {
// prettier-ignore
prop: type
// prettier-ignore
prop: type;
prop: type;
}
// Last element
interface Interface {
// prettier-ignore
prop: type
prop: type;
}
interface foo extends bar {
// prettier-ignore
f(): void;
// prettier-ignore
g(): void;
h(): void;
}
interface T<T> {
// prettier-ignore
new<T>(): T<T>;
new <T>(): T<T>;
}
================================================================================
`;
exports[`ignore.js 2`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
interface Interface {
// prettier-ignore
prop: type
// prettier-ignore
prop: type;
prop: type;
}
// Last element
interface Interface {
// prettier-ignore
prop: type
prop: type
}
interface foo extends bar {
// prettier-ignore
f(): void;
// prettier-ignore
g(): void;
h(): void;
}
interface T<T> {
// prettier-ignore
new<T>(): T<T>;
new<T>(): T<T>;
}
=====================================output=====================================
interface Interface {
// prettier-ignore
prop: type
// prettier-ignore
prop: type;
prop: type
}
// Last element
interface Interface {
// prettier-ignore
prop: type
prop: type
}
interface foo extends bar {
// prettier-ignore
f(): void;
// prettier-ignore
g(): void;
h(): void
}
interface T<T> {
// prettier-ignore
new<T>(): T<T>;
new <T>(): T<T>
}
================================================================================
`;
exports[`long-extends.ts 1`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
| printWidth
=====================================input======================================
export interface I extends A, B, C {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName extends ALongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName extends ALongAndBoringInterfaceName, AnotherLongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName extends AVeryLongAndBoringInterfaceName, AnotherVeryLongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName extends A_AVeryLongAndBoringInterfaceName, B_AVeryLongAndBoringInterfaceName, C_AVeryLongAndBoringInterfaceName {
c: string;
}
=====================================output=====================================
export interface I extends A, B, C {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName
extends ALongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName
extends ALongAndBoringInterfaceName,
AnotherLongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName
extends AVeryLongAndBoringInterfaceName,
AnotherVeryLongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName
extends A_AVeryLongAndBoringInterfaceName,
B_AVeryLongAndBoringInterfaceName,
C_AVeryLongAndBoringInterfaceName {
c: string;
}
================================================================================
`;
exports[`long-extends.ts 2`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
export interface I extends A, B, C {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName extends ALongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName extends ALongAndBoringInterfaceName, AnotherLongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName extends AVeryLongAndBoringInterfaceName, AnotherVeryLongAndBoringInterfaceName {
c: string;
}
export interface ThirdVeryLongAndBoringInterfaceName extends A_AVeryLongAndBoringInterfaceName, B_AVeryLongAndBoringInterfaceName, C_AVeryLongAndBoringInterfaceName {
c: string;
}
=====================================output=====================================
export interface I extends A, B, C {
c: string
}
export interface ThirdVeryLongAndBoringInterfaceName
extends ALongAndBoringInterfaceName {
c: string
}
export interface ThirdVeryLongAndBoringInterfaceName
extends ALongAndBoringInterfaceName,
AnotherLongAndBoringInterfaceName {
c: string
}
export interface ThirdVeryLongAndBoringInterfaceName
extends AVeryLongAndBoringInterfaceName,
AnotherVeryLongAndBoringInterfaceName {
c: string
}
export interface ThirdVeryLongAndBoringInterfaceName
extends A_AVeryLongAndBoringInterfaceName,
B_AVeryLongAndBoringInterfaceName,
C_AVeryLongAndBoringInterfaceName {
c: string
}
================================================================================
`;
exports[`separator.ts 1`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
| printWidth
=====================================input======================================
declare module 'selenium-webdriver' {
export const until: {
ableToSwitchToFrame(frame: number | WebElement | By): Condition<boolean>;
alertIsPresent(): Condition<Alert>;
};
}
export interface Edge {
cursor: {};
node: {
id: {};
};
}
interface Test { one: string, two: any[] }
=====================================output=====================================
declare module "selenium-webdriver" {
export const until: {
ableToSwitchToFrame(frame: number | WebElement | By): Condition<boolean>;
alertIsPresent(): Condition<Alert>;
};
}
export interface Edge {
cursor: {};
node: {
id: {};
};
}
interface Test {
one: string;
two: any[];
}
================================================================================
`;
exports[`separator.ts 2`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
declare module 'selenium-webdriver' {
export const until: {
ableToSwitchToFrame(frame: number | WebElement | By): Condition<boolean>;
alertIsPresent(): Condition<Alert>;
};
}
export interface Edge {
cursor: {};
node: {
id: {};
};
}
interface Test { one: string, two: any[] }
=====================================output=====================================
declare module "selenium-webdriver" {
export const until: {
ableToSwitchToFrame(frame: number | WebElement | By): Condition<boolean>
alertIsPresent(): Condition<Alert>
}
}
export interface Edge {
cursor: {}
node: {
id: {}
}
}
interface Test {
one: string
two: any[]
}
================================================================================
`;