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

374 lines
5.6 KiB
Plaintext

// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`class-declaration.js 1`] = `
class a {
b( ) {}
}
let x~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
class a {
b() {}
}
let x
`;
exports[`different-levels.js 1`] = `
call(1,2,3)
call(1,2,3)
function f() {
call(1,2,3)
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
call(1,2,3)
call(1, 2, 3);
function f() {
call(1, 2, 3);
}
`;
exports[`function-declaration.js 1`] = `
function ugly ( {a=1, b = 2 } ) {}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
function ugly({ a = 1, b = 2 }) {}
`;
exports[`ignore-indentation.js 1`] = `
function ugly ( {a=1, b = 2 } ) {
function ugly ( {a=1, b = 2 } ) {
function ugly ( {a=1, b = 2 } ) {
\`multiline template string
with too much indentation\`
}
}
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
function ugly ( {a=1, b = 2 } ) {
function ugly ( {a=1, b = 2 } ) {
function ugly ( {a=1, b = 2 } ) {
\`multiline template string
with too much indentation\`;
}
}
}
`;
exports[`module-export1.js 1`] = `
import def , {named} from 'x'
export * from 'd'
export const x
= 42
export default 42
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
import def , {named} from 'x'
export * from "d";
export const x
= 42
export default 42
`;
exports[`module-export2.js 1`] = `
import def , {named} from 'x'
export * from 'd'
export const x
= 42
export default 42
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
import def , {named} from 'x'
export * from 'd'
export const x = 42;
export default 42
`;
exports[`module-export3.js 1`] = `
import def , {named} from 'x'
export * from 'd'
export const x
= 42
export default 42
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
import def , {named} from 'x'
export * from 'd'
export const x
= 42
export default 42;
`;
exports[`module-import.js 1`] = `
import def , {named} from 'x'
export * from 'd'
export const x
= 42
export default 42
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
import def, { named } from "x";
export * from 'd'
export const x
= 42
export default 42
`;
exports[`multiple-statements.js 1`] = `
call(
1, 2,3
);
call(
1, 2,3
);
call(
1, 2,3
);
call(
1, 2,3
);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
call(
1, 2,3
);
call(1, 2, 3);
call(1, 2, 3);
call(
1, 2,3
);
`;
exports[`multiple-statements2.js 1`] = `
call(
1, 2,3
);
call(
1, 2,3
);
call(
1, 2,3
);
call(
1, 2,3
);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
call(
1, 2,3
);
call(1, 2, 3);
call(1, 2, 3);
call(
1, 2,3
);
`;
exports[`nested.js 1`] = `
try {
if (condition) {
body
}
}
catch (err) {}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
try {
if (condition) {
body;
}
} catch (err) {}
`;
exports[`nested2.js 1`] = `
try {
if (condition) {
body
}
}
catch (err) {}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
try {
if (condition) {
body;
}
}
catch (err) {}
`;
exports[`nested3.js 1`] = `
try {
1;if (condition) {
body
}
}
catch (err) {}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
try {
1;if (condition) {
body;
}
}
catch (err) {}
`;
exports[`object-expression.js 1`] = `
const y = {a:1, b:2}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
const y = { a: 1, b: 2 };
`;
exports[`object-expression2.js 1`] = `
const y = [
{
a: 1,
},
{
a: 1,
b:2
},
]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
const y = [
{
a: 1
},
{
a: 1,
b: 2
}
];
`;
exports[`range.js 1`] = `
function ugly ( {a=1, b = 2 } ) {
function ugly ( {a=1, b = 2 } ) {
function ugly ( {a=1, b = 2 } ) {
\`multiline template string
with too much indentation\`
}
}
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
function ugly ( {a=1, b = 2 } ) {
function ugly ( {a=1, b = 2 } ) {
function ugly ( {a=1, b = 2 } ) {
\`multiline template string
with too much indentation\`;
}
}
}
`;
exports[`range-end.js 1`] = `
// Unchanged
call(
1, 2,3
);
call(
1, 2,3
);~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Unchanged
call(
1, 2,3
);
call(1, 2, 3);
`;
exports[`range-start.js 1`] = `
call(
1, 2,3
);
// Unchanged
call(
1, 2,3
);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
call(1, 2, 3);
// Unchanged
call(
1, 2,3
);
`;
exports[`try-catch.js 1`] = `
try {}
catch (err) {}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
try {
} catch (err) {}
`;
exports[`whitespace.js 1`] = `
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
`;