Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(json): format test names #4397

Merged
merged 2 commits into from
Feb 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions json/concatenated_json_parse_stream_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { ConcatenatedJsonParseStream } from "./concatenated_json_parse_stream.ts
import { assertInvalidParse, assertValidParse } from "./_test_common.ts";

Deno.test({
name: "[json] ConcatenatedJsonParseStream",
name: "ConcatenatedJsonParseStream",
async fn() {
await assertValidParse(
ConcatenatedJsonParseStream,
Expand Down Expand Up @@ -40,7 +40,7 @@ Deno.test({
});

Deno.test({
name: "[json] ConcatenatedJsonParseStream: primitive",
name: "ConcatenatedJsonParseStream handles primitive",
async fn() {
await assertValidParse(
ConcatenatedJsonParseStream,
Expand Down Expand Up @@ -221,7 +221,7 @@ Deno.test({
});

Deno.test({
name: "[json] ConcatenatedJsonParseStream: chunk",
name: "ConcatenatedJsonParseStream handles chunk",
async fn() {
await assertValidParse(
ConcatenatedJsonParseStream,
Expand Down Expand Up @@ -272,7 +272,7 @@ Deno.test({
});

Deno.test({
name: "[json] ConcatenatedJsonParseStream: surrogate pair",
name: "ConcatenatedJsonParseStream handles surrogate pair",
async fn() {
await assertValidParse(
ConcatenatedJsonParseStream,
Expand All @@ -283,7 +283,7 @@ Deno.test({
});

Deno.test({
name: "[json] ConcatenatedJsonParseStream: symbol between double quotes",
name: "ConcatenatedJsonParseStream handles symbol between double quotes",
async fn() {
await assertValidParse(
ConcatenatedJsonParseStream,
Expand All @@ -294,7 +294,7 @@ Deno.test({
});

Deno.test({
name: "[json] ConcatenatedJsonParseStream: primitives in containers",
name: "ConcatenatedJsonParseStream handles primitives in containers",
async fn() {
await assertValidParse(
ConcatenatedJsonParseStream,
Expand All @@ -305,7 +305,7 @@ Deno.test({
});

Deno.test({
name: "[json] ConcatenatedJsonParseStream: halfway chunk",
name: "ConcatenatedJsonParseStream handles halfway chunk",
async fn() {
await assertInvalidParse(
ConcatenatedJsonParseStream,
Expand All @@ -318,7 +318,7 @@ Deno.test({
});

Deno.test({
name: "[json] ConcatenatedJsonParseStream: truncate error message",
name: "ConcatenatedJsonParseStream truncates error message",
async fn() {
await assertInvalidParse(
ConcatenatedJsonParseStream,
Expand All @@ -332,7 +332,7 @@ Deno.test({

Deno.test({
// Read the test data file
name: "[json] parse: testdata(concatenated-json)",
name: "parse() handles concatenated-json testdata",
async fn() {
const url = "./testdata/test.concatenated-json";
const { body } = await fetch(new URL(url, import.meta.url).toString());
Expand Down
14 changes: 7 additions & 7 deletions json/json_parse_stream_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { JsonParseStream } from "./json_parse_stream.ts";
import { assertInvalidParse, assertValidParse } from "./_test_common.ts";

Deno.test({
name: "[json] JsonParseStream",
name: "JsonParseStream",
async fn() {
await assertValidParse(
JsonParseStream,
Expand All @@ -18,7 +18,7 @@ Deno.test({
});

Deno.test({
name: "[json] JsonParseStream: empty line",
name: "JsonParseStream handles empty line",
async fn() {
await assertValidParse(
JsonParseStream,
Expand All @@ -29,7 +29,7 @@ Deno.test({
});

Deno.test({
name: "[json] JsonParseStream: special character",
name: "JsonParseStream handles special character",
async fn() {
await assertValidParse(
JsonParseStream,
Expand All @@ -40,7 +40,7 @@ Deno.test({
});

Deno.test({
name: "[json] JsonParseStream: expect error",
name: "JsonParseStream handles expect error",
async fn() {
await assertInvalidParse(
JsonParseStream,
Expand All @@ -53,7 +53,7 @@ Deno.test({
});

Deno.test({
name: "[json] parse: testdata(jsonl)",
name: "parse() handles jsonl testdata",
async fn() {
// Read the test data file
const url = "./testdata/test.jsonl";
Expand All @@ -74,7 +74,7 @@ Deno.test({
});

Deno.test({
name: "[json] parse: testdata(ndjson)",
name: "parse() handles ndjson testdata",
async fn() {
// Read the test data file
const url = "./testdata/test.ndjson";
Expand All @@ -95,7 +95,7 @@ Deno.test({
});

Deno.test({
name: "[json] parse: testdata(json-seq)",
name: "parse() handles json-seq testdata",
async fn() {
// Read the test data file
const recordSeparator = "\x1E";
Expand Down
6 changes: 3 additions & 3 deletions json/json_stringify_stream_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ async function assertInvalidStringify(
}

Deno.test({
name: "[json] JsonStringifyStream",
name: "JsonStringifyStream",
async fn() {
await assertValidStringify(
JsonStringifyStream,
Expand All @@ -47,7 +47,7 @@ Deno.test({
});

Deno.test({
name: "[json] JsonStringifyStream: throws",
name: "JsonStringifyStream throws on error",
async fn() {
const cyclic: Record<string, unknown> = {};
cyclic.cyclic = cyclic;
Expand All @@ -62,7 +62,7 @@ Deno.test({
});

Deno.test({
name: "[json] JsonStringifyStream: prefix and suffix",
name: "JsonStringifyStream handles prefix and suffix",
async fn() {
await assertValidStringify(
JsonStringifyStream,
Expand Down