Skip to content
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
13 changes: 4 additions & 9 deletions lib/core/engine/context.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ export class Context {
) {
/**
* This is the yargs object you get from the cli. If you add --my.id you can get that using options.my.id.
* @type {Object}
* @type {Record<string, any>}
*/
this.options = options;

/**
* Here the result from each run is stored.
* @type {Object}
* @type {Record<string, any>}
*/
this.result = result;

Expand All @@ -58,7 +58,8 @@ export class Context {
this.storageManager = storageManager;

/**
* @type {Object}
* Scratch space shared between commands within a single iteration.
* @type {Record<string, any>}
*/
this.taskData = {};

Expand All @@ -68,13 +69,7 @@ export class Context {
* @type {{webdriver: WebDriverClass, driver: WebDriverInstance}}
*/
this.selenium = {
/**
* @typedef {typeof import('selenium-webdriver')} WebDriverClass
*/
webdriver,
/**
* @typedef {import('selenium-webdriver').WebDriver} WebDriverInstance
*/
driver: instantiatedDriver
};
}
Expand Down
6 changes: 3 additions & 3 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@
"lib/core/engine/commands.js"
],
"compilerOptions": {
"target": "ES2020",
"allowJs": true,
"declaration": true,
"emitDeclarationOnly": true,
"outDir": "types",
"declarationMap": true,
"esModuleInterop": true,
"skipLibCheck": true
},
"target": "ES2020"
}
}
}
17 changes: 9 additions & 8 deletions types/core/engine/context.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,14 @@ export class Context {
constructor(options: any, result: any, log: any, storageManager: any, index: any, webdriver: any, instantiatedDriver: any);
/**
* This is the yargs object you get from the cli. If you add --my.id you can get that using options.my.id.
* @type {Object}
* @type {Record<string, any>}
*/
options: any;
options: Record<string, any>;
/**
* Here the result from each run is stored.
* @type {Object}
* @type {Record<string, any>}
*/
result: any;
result: Record<string, any>;
/**
* @type {Logger}
*/
Expand All @@ -43,17 +43,18 @@ export class Context {
*/
storageManager: import("../../support/storageManager.js").StorageManager;
/**
* @type {Object}
* Scratch space shared between commands within a single iteration.
* @type {Record<string, any>}
*/
taskData: any;
taskData: Record<string, any>;
/**
* Get raw Selenium functionality.
* @see https://www.selenium.dev/selenium/docs/api/javascript/module/selenium-webdriver/index.html
* @type {{webdriver: WebDriverClass, driver: WebDriverInstance}}
*/
selenium: {
webdriver: typeof import("selenium-webdriver");
driver: import("selenium-webdriver").WebDriver;
webdriver: WebDriverClass;
driver: WebDriverInstance;
};
}
export type Logger = {
Expand Down
2 changes: 1 addition & 1 deletion types/core/engine/context.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading