1 | static S testStructureFunction(O input) {
|
2 | ret testStructureFunction(input, true); |
3 | } |
4 | |
5 | static S testStructureFunction(O input, bool compare) {
|
6 | S s; |
7 | time {
|
8 | s = structure(input); |
9 | } |
10 | print("struct", shorten(s, 500));
|
11 | O o; |
12 | print("unstructuring " + l(s) + " chars");
|
13 | time {
|
14 | o = unstructure(s); |
15 | } |
16 | S x = structure(o); |
17 | assertEquals(s, x); |
18 | if (compare) |
19 | assertEqualsVerbose(input, o); |
20 | ret x; |
21 | } |
download show line numbers debug dex old transpilations
Travelled to 15 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ekrmjmnbrukm, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1003319 |
| Snippet name: | testStructureFunction - tests if structure stays the same and (by default) also if object is equal restructured object |
| Eternal ID of this version: | #1003319/4 |
| Text MD5: | 7664747a00f45aab478a77c699363bbd |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2022-08-21 05:25:29 |
| Source code size: | 438 bytes / 21 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 872 / 872 |
| Version history: | 3 change(s) |
| Referenced in: | [show references] |