mongo/buildscripts/tests/resmoke_end2end/testfiles/validatecollections/test_fail.js
Zac 591928c619 SERVER-108478 JS formatted by prettier and remove clang-format (#39656)
GitOrigin-RevId: 6c8f6aded47f260aa4f7c231b17dae3302cb1e04
2025-08-21 17:27:09 +00:00

17 lines
381 B
JavaScript

const t = db.test_validate_failure;
t.drop();
const adminDB = db.getSiblingDB("admin");
assert.commandWorked(t.insert({_id: 1, x: 1}));
assert.commandWorked(
adminDB.runCommand({
configureFailPoint: "failCommand",
mode: "alwaysOn",
data: {
errorCode: ErrorCodes.InternalError,
failCommands: ["validate"],
},
}),
);