Skip to content

Commit aae3a48

Browse files
autarchclaude
andcommitted
migration: annotate JS tests with verified Go coverage triage
Adds a // MIGRATION: comment to the first line of every JS test file under test/qa-tests/ and test/legacy42/ indicating its migration status: - SKIP (27 files): genuinely covered by existing Go tests, broken pipe tests (OS-signal-level, not testable in Go), or already disabled - NEW (111 files): no Go test coverage exists for this scenario - EXTEND (41 files): partial Go coverage exists but specific sub-scenarios are missing Each annotation includes the justification and the target Go test file. Co-Authored-By: Claude Code <noreply@anthropic.com>
1 parent 00b26a2 commit aae3a48

180 files changed

Lines changed: 653 additions & 287 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.ai-plans/2026-03-13/js-to-go-test-migration/plan.md

Lines changed: 474 additions & 287 deletions

test/legacy42/jstests/tool/command_line_quotes.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: NEW — no Go coverage, goes in common/util test or tool-specific test
12
jsTest.log("Testing spaces in mongodump command-line options...");
23

34
/**

test/legacy42/jstests/tool/csv1.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: EXTEND — csv_test.go covers unit-level CSV parsing but no Go test covers end-to-end CSV export then re-import with --headerline; goes in mongoexport/mongoexport_test.go
12
// csv1.js
23

34
t = new ToolTest("csv1");

test/legacy42/jstests/tool/csvexport1.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: NEW — no Go test exports various BSON types (ObjectId, BinData, ISODate, Timestamp, Regex, function) to CSV and verifies formatting; goes in mongoexport/mongoexport_test.go
12
// csvexport1.js
23

34
t = new ToolTest("csvexport1");

test/legacy42/jstests/tool/csvexport2.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: SKIP — csv_test.go covers CSV export variants
12
// csvexport2.js
23

34
t = new ToolTest("csvexport2");

test/legacy42/jstests/tool/csvimport1.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: EXTEND — csv_test.go covers parsing but no Go test covers end-to-end import of multiline CSV with embedded quotes, empty strings, and leading/trailing whitespace; goes in mongoimport/mongoimport_test.go
12
// csvimport1.js
23

34
t = new ToolTest("csvimport1");

test/legacy42/jstests/tool/dumpauth.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: EXTEND — TestDumpRestoreEnforcesAuthRoles covers backup/restore roles but does not verify system.profile is included in the dump; goes in mongorestore/dumprestore_auth_test.go
12
// dumpauth.js
23
// test mongodump with authentication
34

test/legacy42/jstests/tool/dumprestore1.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: EXTEND — basic dump/restore covered but missing --collection without --db error (SERVER-7721) and --dir - without --db --collection error; goes in mongodump/mongodump_qa_test.go
12
// dumprestore1.js
23

34
t = new ToolTest("dumprestore1");

test/legacy42/jstests/tool/dumprestore10.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: NEW — no Go coverage, goes in dumprestore_auth_test.go (ReplSetTestType)
12
// simple test to ensure write concern functions as expected
23
(function() {
34
// Skip this test if running with --nojournal and WiredTiger.

test/legacy42/jstests/tool/dumprestore3.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// MIGRATION: NEW — no Go coverage, goes in mongorestore_test.go (ReplSetTestType)
12
// mongodump/mongoexport from primary should succeed. mongorestore and mongoimport to a
23
// secondary node should fail.
34

0 commit comments

Comments
 (0)