Oregami
Repositories/oxedyne/fe2o3

oxedyne/fe2o3/fe2o3_austenite/tests/fixtures/eval/foundation/data.txt

2.5 KiB, 1 run

created by r1870400018:63826, which is this file's identity for as long as the history lasts, whatever it is later renamed to

download · who wrote it · its history

1// data formats read from bytes and written back.
2json(bytes("[1, 2.5, \"x\", true, null, {\"k\": [1e2, -0, 3]}]"))
3json(bytes("{\"b\":1,\"a\":2.0,\"c\":[12345678901234567890]}"))
4json(bytes("\"\\u00e9\\ud83d\\ude00\\n\\t\""))
5json(bytes(" {} "))
6json.encode((a: 1, b: (1.5, none, true, "x")))
7json.encode((a: 1), pretty: false)
8json.encode(((a: ()), (:), 1.0, -0.0, 1e300, float.nan))
9json.encode("é\u{1}\"")
10json.encode(1pt)
11json.encode(datetime(year: 2020, month: 1, day: 2))
12json.encode((0.1, 1e-5, 1e-7, 1e16, 123456.789, 1e21))
13csv(bytes("a,b\n1,2\n\"x,y\",3"))
14csv(bytes("a;b\n1;2"), delimiter: ";")
15csv(bytes("a,b\n1,2"), row-type: dictionary)
16csv(bytes("a,\"b\"\"c\"\n\"multi\nline\",2\n"))
17csv(bytes("a,b\r\n1,2\r\n"))
18toml(bytes("a = 1\nb = \"x\"\n[t]\nc = [1, 2.5]\nd = 1979-05-27\ne = 07:32:00\nf = 1979-05-27T07:32:00Z"))
19toml(bytes("x.y.z = 1\nx.w = 'lit'\n[[arr]]\nn = 1\n[[arr]]\nn = 2\n[tab]\ninl = { a = 1, b = [true, false] }\nhex = 0xff\noct = 0o17\nbin = 0b101\nbig = 1_000_000\nf = 6.02e23\ninf = -inf\n"))
20toml(bytes("s = \"\"\"\nmulti\\\n line\"\"\"\nl = '''\nraw\\n'''\nesc = \"tab\\tq\\\"\\u00e9\""))
21toml.encode((a: 1, arr: (1, 2), s: "x\"y", f: 1.5, t: (x: (y: 1)), aot: ((n: 1), (n: 2)), d: datetime(year: 2020, month: 1, day: 2)))
22toml.encode((a: 1, arr: (1, 2)), pretty: false)
23toml.encode((a: none))
24toml.encode((s: "plain", k: (m: "x", n: (o: 1))))
25yaml(bytes("a: 1\nb: [x, 2.5, true, ~]\nc:\n d: e\n"))
26yaml(bytes("- a\n- b: 1\n c: [1, {d: 2}]\n- |\n lit\n text\n- >\n folded\n text\n- 'q''s'\n- \"e\\n\"\n- 0x10\n- 1e3\n- .inf\n- yes\n- null\n"))
27yaml(bytes("a: &x 1\nb: *x\n"))
28yaml(bytes("--- \nfoo\n"))
29yaml(bytes("a:\n - 1\n - 2\nb: 2"))
30yaml(bytes("# comment\nkey: value # trailing\nlist:\n- one\n- two\nnested:\n deeper:\n x: -3\n y: 0o17\n"))
31yaml(bytes("text: |-\n keep\n lines\nfold: >-\n one\n two\n\n three\n"))
32yaml.encode((a: "x", b: 1.5, c: none, d: (), e: (:), f: "a: b", g: "1", h: true, i: ((x: 1), (y: 2)), j: "multi\nline"))
33yaml.encode((1, "two", (three: 3)))
34xml(bytes("<a x=\"1\">hi<b/>t</a>"))
35xml(bytes("<?xml version=\"1.0\"?><r><c a=\"&amp;\">&lt;x&gt;</c><!-- no --></r>"))
36cbor(bytes((0xa1, 0x61, 0x61, 0x01)))
37array(cbor.encode((1, -1, 1.5, 100000, "s", bytes((1,)), true, none, 1.1)))
38cbor(cbor.encode((a: (1, 2.5), b: "x")))
39array(cbor.encode((a: 65536, b: -500, c: 3.4028234663852886e38)))
40!json(bytes("{\"a\": 1,}"))
41!json(bytes("[1e400]"))
42!json(bytes("[1, 2"))
43!~json(bytes("nope"))
44!csv(bytes("a,b\n1"))
45!~toml(bytes("a = 1\na = 2"))
46!~toml(bytes("a = "))
47!toml.encode(1)
48!~cbor(bytes((0xa1,)))