Skip to content

TOOLS-4148 Convert test/qa-tests/jstests/import/fields.js to Go#951

Open
autarch wants to merge 1 commit into03-23-convert_test/qa-tests/jstests/import/decimal128.js_to_gofrom
03-23-convert_test/qa-tests/jstests/import/fields.js_to_go
Open

TOOLS-4148 Convert test/qa-tests/jstests/import/fields.js to Go#951
autarch wants to merge 1 commit into03-23-convert_test/qa-tests/jstests/import/decimal128.js_to_gofrom
03-23-convert_test/qa-tests/jstests/import/fields.js_to_go

Conversation

@autarch
Copy link
Collaborator

@autarch autarch commented Mar 23, 2026

No description provided.

This was referenced Mar 23, 2026
Copy link
Collaborator Author

autarch commented Mar 23, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@autarch autarch requested a review from a team as a code owner March 24, 2026 15:04
@autarch autarch requested review from FGasper and removed request for a team March 24, 2026 15:04
@autarch autarch changed the title Convert test/qa-tests/jstests/import/fields.js to Go TOOLS-4148 Convert test/qa-tests/jstests/import/fields.js to Go Mar 24, 2026
Copy link
Collaborator

@FGasper FGasper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few nits.

Thanks!

) {
t.Helper()

comma := map[string]rune{
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggest “separator” instead of calling a tab a comma.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

comma := map[string]rune{
"csv": ',',
"tsv": '\t',
}[format]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
}[format]
}[format]
require.NotEmpty(t, separator, "%#q format needs separator", format)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added.

assert.Equal(t, "extra3", doc["field6"], "field6 should contain third extra value")
}

func writeCSVFile(t *testing.T, path string, comma rune, records [][]string) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggest not calling a thing that creates TSV writeCSVFile.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Renamed to writeXSVFile

@autarch autarch changed the base branch from 03-23-add_another_task_to_the_plan to graphite-base/951 March 25, 2026 21:17
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/fields.js_to_go branch from a14964c to 4effa81 Compare March 25, 2026 21:17
@autarch autarch changed the base branch from graphite-base/951 to master March 25, 2026 21:17
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/fields.js_to_go branch from 4effa81 to cb84c46 Compare March 25, 2026 21:19
@autarch autarch changed the base branch from master to graphite-base/951 March 25, 2026 21:20
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/fields.js_to_go branch from cb84c46 to 86146e5 Compare March 25, 2026 21:20
@autarch autarch changed the base branch from graphite-base/951 to 03-23-convert_test/qa-tests/jstests/import/decimal128.js_to_go March 25, 2026 21:20
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/decimal128.js_to_go branch from c3598aa to 7001c73 Compare March 26, 2026 01:25
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/fields.js_to_go branch from 86146e5 to c38e130 Compare March 26, 2026 17:08
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/decimal128.js_to_go branch 2 times, most recently from 2106629 to f15c803 Compare March 26, 2026 17:23
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/fields.js_to_go branch 2 times, most recently from 6de2ce2 to 68992ec Compare March 26, 2026 21:53
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/decimal128.js_to_go branch from f15c803 to 1d13fae Compare March 26, 2026 21:53
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/fields.js_to_go branch from 68992ec to e96d0a3 Compare March 26, 2026 22:02
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/decimal128.js_to_go branch from 1d13fae to fd1616a Compare March 26, 2026 22:02
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/decimal128.js_to_go branch from fd1616a to caace78 Compare March 26, 2026 22:03
@autarch autarch force-pushed the 03-23-convert_test/qa-tests/jstests/import/fields.js_to_go branch from e96d0a3 to 02e7ab3 Compare March 26, 2026 22:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants