mirror of
https://github.com/RGBCube/serenity
synced 2025-07-03 05:22:08 +00:00
test-js: Use prettier and format all files
This commit is contained in:
parent
e532888242
commit
6d58c48c2f
248 changed files with 8291 additions and 7725 deletions
|
@ -1,17 +1,20 @@
|
|||
test("basic functionality", () => {
|
||||
let o = {
|
||||
foo: 1,
|
||||
bar: "baz",
|
||||
qux: {
|
||||
get x() { return 10; },
|
||||
y() { return 20; },
|
||||
arr: [1, 2, 3],
|
||||
}
|
||||
};
|
||||
let o = {
|
||||
foo: 1,
|
||||
bar: "baz",
|
||||
qux: {
|
||||
get x() {
|
||||
return 10;
|
||||
},
|
||||
y() {
|
||||
return 20;
|
||||
},
|
||||
arr: [1, 2, 3],
|
||||
},
|
||||
};
|
||||
|
||||
let string = JSON.stringify(o, null, 4);
|
||||
let expected =
|
||||
`{
|
||||
let string = JSON.stringify(o, null, 4);
|
||||
let expected = `{
|
||||
"foo": 1,
|
||||
"bar": "baz",
|
||||
"qux": {
|
||||
|
@ -24,11 +27,10 @@ test("basic functionality", () => {
|
|||
}
|
||||
}`;
|
||||
|
||||
expect(string).toBe(expected);
|
||||
expect(string).toBe(expected);
|
||||
|
||||
string = JSON.stringify(o, null, "abcd");
|
||||
expected =
|
||||
`{
|
||||
string = JSON.stringify(o, null, "abcd");
|
||||
expected = `{
|
||||
abcd"foo": 1,
|
||||
abcd"bar": "baz",
|
||||
abcd"qux": {
|
||||
|
@ -41,5 +43,5 @@ abcdabcd]
|
|||
abcd}
|
||||
}`;
|
||||
|
||||
expect(string).toBe(expected);
|
||||
expect(string).toBe(expected);
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue