mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-20 01:52:53 +00:00
Libraries: Move to Userland/Libraries/
This commit is contained in:
parent
dc28c07fa5
commit
13d7c09125
Notes:
sideshowbarker
2024-07-18 23:53:55 +09:00
Author: https://github.com/awesomekling
Commit: 13d7c09125
1857 changed files with 266 additions and 274 deletions
|
@ -1,47 +0,0 @@
|
|||
test("basic functionality", () => {
|
||||
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 = `{
|
||||
"foo": 1,
|
||||
"bar": "baz",
|
||||
"qux": {
|
||||
"x": 10,
|
||||
"arr": [
|
||||
1,
|
||||
2,
|
||||
3
|
||||
]
|
||||
}
|
||||
}`;
|
||||
|
||||
expect(string).toBe(expected);
|
||||
|
||||
string = JSON.stringify(o, null, "abcd");
|
||||
expected = `{
|
||||
abcd"foo": 1,
|
||||
abcd"bar": "baz",
|
||||
abcd"qux": {
|
||||
abcdabcd"x": 10,
|
||||
abcdabcd"arr": [
|
||||
abcdabcdabcd1,
|
||||
abcdabcdabcd2,
|
||||
abcdabcdabcd3
|
||||
abcdabcd]
|
||||
abcd}
|
||||
}`;
|
||||
|
||||
expect(string).toBe(expected);
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue