mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-11 12:30:18 +00:00
Fix issue #6065
* Update the Runner.run function. * Update the Server.new function. * Add new Config interface. * Add new ConfigFile interface. * Rename ClientConfig to ClientOptions.
This commit is contained in:
Vendored
+18
-5
@@ -53,11 +53,11 @@ declare module 'karma' {
|
||||
}
|
||||
|
||||
interface Runner {
|
||||
run(options?: Config, callback?: ServerCallback): void;
|
||||
run(options?: ConfigOptions|ConfigFile, callback?: ServerCallback): void;
|
||||
}
|
||||
|
||||
interface Server extends NodeJS.EventEmitter {
|
||||
new(options?: Config, callback?: ServerCallback): Server;
|
||||
new(options?: ConfigOptions|ConfigFile, callback?: ServerCallback): Server;
|
||||
/**
|
||||
* Start the server
|
||||
*/
|
||||
@@ -82,8 +82,21 @@ declare module 'karma' {
|
||||
interface ServerCallback {
|
||||
(exitCode: number): void;
|
||||
}
|
||||
|
||||
interface Config {
|
||||
set: (config: ConfigOptions) => void;
|
||||
LOG_DISABLE: string;
|
||||
LOG_ERROR: string;
|
||||
LOG_WARN: string;
|
||||
LOG_INFO: string;
|
||||
LOG_DEBUG: string;
|
||||
}
|
||||
|
||||
interface ConfigFile {
|
||||
configFile: string;
|
||||
}
|
||||
|
||||
interface Config {
|
||||
interface ConfigOptions {
|
||||
/**
|
||||
* @description Enable or disable watching files and executing the tests whenever one of these files changes.
|
||||
* @default true
|
||||
@@ -163,7 +176,7 @@ declare module 'karma' {
|
||||
* </p>
|
||||
*/
|
||||
captureTimeout?: number;
|
||||
client?: ClientConfig;
|
||||
client?: ClientOptions;
|
||||
/**
|
||||
* @default true
|
||||
* @description Enable or disable colors in the output (reporters and logs).
|
||||
@@ -308,7 +321,7 @@ declare module 'karma' {
|
||||
urlRoot?: string;
|
||||
}
|
||||
|
||||
interface ClientConfig {
|
||||
interface ClientOptions {
|
||||
/**
|
||||
* @default undefined
|
||||
* @description When karma run is passed additional arguments on the command-line, they
|
||||
|
||||
Reference in New Issue
Block a user