mirror of
https://github.com/cypress-io/cypress.git
synced 2026-03-10 02:28:52 -05:00
* chore: use import type across repo * chore: use import type across repo * chore: use import type across repo * chore: use import type across repo * update exports * update test * update import type * update types * use import type in driver * correctly export function * revert test * remove unrelated code * revert code * improve type imports * override for reporter
20 lines
450 B
TypeScript
20 lines
450 B
TypeScript
import type { NotInstalledError, NotDetectedAtPathError } from './types'
|
|
|
|
export const notInstalledErr = (name: string, message?: string) => {
|
|
const err = new Error(
|
|
message || `Browser not installed: ${name}`,
|
|
) as NotInstalledError
|
|
|
|
err.notInstalled = true
|
|
|
|
return err
|
|
}
|
|
|
|
export const notDetectedAtPathErr = (stdout: string) => {
|
|
const err = new Error(stdout) as NotDetectedAtPathError
|
|
|
|
err.notDetectedAtPath = true
|
|
|
|
return err
|
|
}
|