import {TakePhotosBeforeAndAfterInteractions} from '@serenity-js/webdriverio/lib/stage/crew/photographer/strategies'
public class | source

TakePhotosBeforeAndAfterInteractions

Configures the Photographer to take photos (a.k.a. screenshots) both before and after every single Interaction performed by the Actor in the spotlight.

Please note that this strategy will result in a lot of screenshots being taken, which will seriously affect the performance of your tests. For this reason, it's best to use it only for debugging purposes.

Extends:

PhotoTakingStrategy → TakePhotosBeforeAndAfterInteractions

Method Summary

Protected Methods
protected

photoNameFor(event: InteractionStarts | InteractionFinished): string

protected

shouldTakeAPhotoOf(event: DomainEvent): boolean

Inherited Summary

From class PhotoTakingStrategy
public

considerTakingPhoto(event: ActivityStarts | @serenity-js/core/lib/events~ActivityFinished, stage: Stage): void

Takes a photo of the web browser held by the Actor in the spotlight.

Protected Methods

protected photoNameFor(event: InteractionStarts | InteractionFinished): string source

Params:

NameTypeAttributeDescription
event InteractionStarts | InteractionFinished

Returns:

string

protected shouldTakeAPhotoOf(event: DomainEvent): boolean source

Params:

NameTypeAttributeDescription
event DomainEvent

Returns:

boolean