Files
orca/tests/e2e/helpers/electron-launch-args.unit.test.ts
Neil dce5ebd83d test: isolate native crash restoration and refresh stale fixtures (#18883)
* test: isolate native crash restoration and seed current integration facts

* test: await scoped GitLab preflight before URL transition checks
2026-09-05 14:18:22 -07:00

25 lines
778 B
TypeScript

import { join } from 'node:path'
import { describe, expect, it } from 'vitest'
import { getOrcaElectronLaunchArgs } from './electron-launch-args'
describe('getOrcaElectronLaunchArgs', () => {
it('launches the package root that owns the compiled main entry', () => {
const root = join('workspace', 'orca')
const mainPath = join(root, 'out', 'main', 'index.js')
const args = getOrcaElectronLaunchArgs(mainPath, true)
if (process.platform === 'darwin') {
expect(args).toEqual([
'--password-store=basic',
'--use-mock-keychain',
root,
'-ApplePersistenceIgnoreState',
'YES'
])
} else {
expect(args.at(-1)).toBe(root)
}
expect(getOrcaElectronLaunchArgs(mainPath, false)).toContain(root)
})
})