mirror of
https://github.com/morluto/rea.git
synced 2026-11-11 01:13:39 +00:00
test: consolidate JavaScript and provider fixture coverage
This commit is contained in:
1 parent
439c197c3f
commit
3c4be703cd
16 files changed
+23
-223
No files matched your search
@@ -458,20 +458,10 @@ it("keeps signed zero and non-finite float and complex constants JSON-safe", ()
|
||||
it("truncates string previews without introducing a lone surrogate", () => {
|
||||
const prefix = "x".repeat(79);
|
||||
const report = parse(
|
||||
withConsts([
|
||||
marshalUnicode(Buffer.from(`${prefix}😀tail`)),
|
||||
marshalUnicode(
|
||||
Buffer.concat([
|
||||
Buffer.from(prefix),
|
||||
Buffer.from("eda080", "hex"),
|
||||
Buffer.from("tail"),
|
||||
]),
|
||||
),
|
||||
]),
|
||||
withConsts([marshalUnicode(Buffer.from(`${prefix}😀tail`))]),
|
||||
);
|
||||
expect(root(report).consts).toEqual([
|
||||
{ kind: "str", bytes: 87, truncated: true, value: prefix },
|
||||
{ kind: "str", bytes: 86, truncated: true, value: `${prefix}\ud800` },
|
||||
]);
|
||||
});
|
||||
|
||||
|
||||
Reference in new issue
Block a user