mongodb-memory-server-core
Version:
MongoDB Server for testing (core package, without autodownload). The server will allow you to connect your favourite ODM or client library to the MongoDB Server and run parallel integration tests isolated from each other.
96 lines • 2.65 kB
TypeScript
import { AnyOS, LinuxOS } from './getos';
export interface MongoBinaryDownloadUrlOpts {
version: string;
platform: string;
arch: string;
os?: AnyOS;
}
/**
* Download URL generator
*/
export declare class MongoBinaryDownloadUrl implements MongoBinaryDownloadUrlOpts {
platform: string;
arch: string;
version: string;
os?: AnyOS;
constructor(opts: MongoBinaryDownloadUrlOpts);
/**
* Assemble the URL to download
* Calls all the necessary functions to determine the URL
*/
getDownloadUrl(): Promise<string>;
/**
* Get the archive
*/
getArchiveName(): Promise<string>;
/**
* Get the archive for Windows
* (from: https://www.mongodb.org/dl/win32)
*/
getArchiveNameWin(): string;
/**
* Get the archive for OSX (Mac)
* (from: https://www.mongodb.org/dl/osx)
*/
getArchiveNameOsx(): string;
/**
* Get the archive for Linux
* (from: https://www.mongodb.org/dl/linux)
*/
getArchiveNameLinux(): Promise<string>;
/**
* Get the version string (with distro)
* @param os LinuxOS Object
*/
getLinuxOSVersionString(os: LinuxOS): string;
/**
* Get the version string for Debian
* @param os LinuxOS Object
*/
getDebianVersionString(os: LinuxOS): string;
/**
* Get the version string for Fedora
* @param os LinuxOS Object
*/
getFedoraVersionString(os: LinuxOS): string;
/**
* Get the version string for Red Hat Enterprise Linux
* @param os LinuxOS Object
*/
getRhelVersionString(os: LinuxOS): string;
/**
* Get the version string for Amazon Distro
* @param os LinuxOS Object
*/
getAmazonVersionString(os: LinuxOS): string;
/**
* Linux Fallback
*/
getLegacyVersionString(): string;
/**
* Get the version string for Suse / OpenSuse
* @param os LinuxOS Object
*/
getSuseVersionString(os: LinuxOS): string;
/**
* Get the version string for Ubuntu
* @param os LinuxOS Object
*/
getUbuntuVersionString(os: LinuxOS): string;
/**
* Translate input platform to mongodb useable platform
* @example
* darwin -> osx
* @param platform The Platform to translate
*/
translatePlatform(platform: string): string;
/**
* Translate input arch to mongodb useable arch
* @example
* x64 -> x86_64
* @param platform The Platform to translate
*/
static translateArch(arch: string, mongoPlatform: string): string;
}
export default MongoBinaryDownloadUrl;
//# sourceMappingURL=MongoBinaryDownloadUrl.d.ts.map