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

docs: update migration docs urls to include new /migration path (closes #571) #572

Merged
merged 1 commit into from
Nov 5, 2021
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
2 changes: 1 addition & 1 deletion docs/guides/error-warning-details.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Example:
```txt
Incorrect State for operation: "${gotState}", allowed States: "[${wantedStates.join(',')}]"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything
```

Details:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,45 +7,45 @@ exports[`MongoMemoryReplSet getters & setters setter of "replSetOpts" should thr
exports[`MongoMemoryReplSet getters & setters state errors setter of "binaryOpts" should throw an error if state is not "stopped" 1`] = `
"Incorrect State for operation: \\"init\\", allowed States: \\"[stopped]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`MongoMemoryReplSet getters & setters state errors setter of "instanceOpts" should throw an error if state is not "stopped" 1`] = `
"Incorrect State for operation: \\"init\\", allowed States: \\"[stopped]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`MongoMemoryReplSet getters & setters state errors setter of "replSetOpts" should throw an error if state is not "stopped" 1`] = `
"Incorrect State for operation: \\"init\\", allowed States: \\"[stopped]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`single server replset "_initReplSet" should throw an error if _state is not "init" 1`] = `
"Incorrect State for operation: \\"running\\", allowed States: \\"[init]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`single server replset "_initReplSet" should throw if server count is 0 or less 1`] = `"One or more servers are required."`;

exports[`single server replset "getUri" should throw an error if _state is not "running" or "init" 1`] = `
"Incorrect State for operation: \\"stopped\\", allowed States: \\"[running,init]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`single server replset "new" should throw an error if replSet count is 0 or less 1`] = `"ReplSet Count needs to be 1 or higher! (specified count: \\"0\\")"`;

exports[`single server replset "start" should throw an error if _state is not "stopped" 1`] = `
"Incorrect State for operation: \\"running\\", allowed States: \\"[stopped]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`single server replset "waitUntilRunning" should throw an error if _state is not "init" 1`] = `
"Incorrect State for operation: \\"stopped\\", allowed States: \\"[running,init]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ exports[`MongoMemoryServer "createAuth" should throw an error if called without
exports[`MongoMemoryServer cleanup() should throw an error if state is not "stopped" 1`] = `
"Incorrect State for operation: \\"new\\", allowed States: \\"[stopped]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`MongoMemoryServer ensureInstance() should throw an error if "instanceInfo" is undefined but "_state" is "running" 1`] = `"{\\"isRunning\\":true,\\"message\\":\\"\\\\\\"ensureInstance\\\\\\" failed, because state was \\\\\\"running\\\\\\" but \\\\\\"instanceInfo\\\\\\" was undefined!\\"}"`;
Expand All @@ -15,31 +15,31 @@ exports[`MongoMemoryServer ensureInstance() should throw an error if no "instanc
exports[`MongoMemoryServer ensureInstance() should throw an error if the given "_state" has no case 1`] = `
"Incorrect State for operation: \\"not Existing\\", allowed States: \\"[running,new,stopped,starting]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`MongoMemoryServer getUri() should throw an state error, if not starting or running 1`] = `
"Incorrect State for operation: \\"new\\", allowed States: \\"[running,starting]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`MongoMemoryServer getUri() should throw an state error, if not starting or running 2`] = `
"Incorrect State for operation: \\"new\\", allowed States: \\"[running,starting]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`MongoMemoryServer start() "createAuth" should not be called if "disabled" is true 1`] = `"Unauthorized"`;

exports[`MongoMemoryServer start() should throw an error if state is not "new" or "stopped" 1`] = `
"Incorrect State for operation: \\"starting\\", allowed States: \\"[new,stopped]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;

exports[`MongoMemoryServer start() should throw an error if state is not "new" or "stopped" 2`] = `
"Incorrect State for operation: \\"running\\", allowed States: \\"[new,stopped]\\"
This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:
https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything"
`;
2 changes: 1 addition & 1 deletion packages/mongodb-memory-server-core/src/util/errors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export class StateError extends Error {
','
)}]"\n` +
'This may be because of using a v6.x way of calling functions, look at the following guide if anything applies:\n' +
'https://nodkz.github.io/mongodb-memory-server/docs/guides/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything'
'https://nodkz.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything'
);
}
}
Expand Down