Functions

Static Public Summary
public

Monkey-patches Jasmine's Suite and Spec so that they provide more accurate information and returns a bootstrapped instance of the SerenityReporterForJasmine to be registered with Jasmine.

public

monkeyPatched(jasmineConstructor: *, wrappers: object): *

Monkey-patches Jasmine domain model constructors so that they record information about the file system location of the caller function.

Static Public

public bootstrap(jasmine: jasmine): SerenityReporterForJasmine source

import {bootstrap} from '@serenity-js/jasmine'

Monkey-patches Jasmine's Suite and Spec so that they provide more accurate information and returns a bootstrapped instance of the SerenityReporterForJasmine to be registered with Jasmine.

Params:

NameTypeAttributeDescription
jasmine jasmine

the global.jasmine instance

Examples:

Registering the reporter from the command line
jasmine --reporter=@serenity-js/jasmine
Registering the reporter programmatically
import serenityReporterForJasmine = require('@serenity-js/jasmine');

jasmine.getEnv().addReporter(serenityReporterForJasmine);

public monkeyPatched(jasmineConstructor: *, wrappers: object): * source

import {monkeyPatched} from '@serenity-js/jasmine'

Monkey-patches Jasmine domain model constructors so that they record information about the file system location of the caller function.

This helps to make reporting more accurate.

Params:

NameTypeAttributeDescription
jasmineConstructor *

A Jasmine constructor function to be patched

wrappers object

Attributes to wrap when the monkey-patched Jasmine constructor is invoked

Returns:

*