import type { Logger } from 'src/core/server' ; import { createMockBrowserDriverFactory } from './browsers/mock' ; import { createMockScreenshots } from './screenshots/mock' ; import type { ScreenshottingStart } from '.' ; export function createMockScreenshottingStart ( ) { const driver = createMockBrowserDriverFactory ( ) ; const { getScreenshots } = createMockScreenshots ( ) ; const { diagnose } = driver ; return { diagnose , getScreenshots : jest . fn ( ( options ) => getScreenshots ( driver , { } as Logger , options ) ) , } ; }