@hyperfixi/testing-framework 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assertions-BImuwZsB.d.mts +458 -0
- package/dist/assertions-BImuwZsB.d.ts +458 -0
- package/dist/assertions.d.mts +1 -0
- package/dist/assertions.d.ts +1 -0
- package/dist/assertions.js +625 -0
- package/dist/assertions.js.map +1 -0
- package/dist/assertions.mjs +621 -0
- package/dist/assertions.mjs.map +1 -0
- package/dist/index.d.mts +246 -0
- package/dist/index.d.ts +246 -0
- package/dist/index.js +1465 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +1435 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +121 -0
- package/src/assertions.test.ts +490 -0
- package/src/assertions.ts +779 -0
- package/src/index.test.ts +490 -0
- package/src/index.ts +601 -0
- package/src/jsdom.d.ts +7 -0
- package/src/multilingual/README.md +295 -0
- package/src/multilingual/bundle-builder.ts +345 -0
- package/src/multilingual/cli.ts +224 -0
- package/src/multilingual/index.ts +68 -0
- package/src/multilingual/orchestrator.ts +275 -0
- package/src/multilingual/pattern-loader.ts +176 -0
- package/src/multilingual/reporters/console-reporter.ts +294 -0
- package/src/multilingual/reporters/json-reporter.ts +99 -0
- package/src/multilingual/reporters/regression-reporter.ts +263 -0
- package/src/multilingual/tools/analyze-failures.ts +326 -0
- package/src/multilingual/types.ts +268 -0
- package/src/multilingual/validators/parse-diagnostics.ts +337 -0
- package/src/multilingual/validators/parse-validator.ts +193 -0
- package/src/multilingual/validators/size-validator.ts +187 -0
- package/src/runner.test.ts +813 -0
- package/src/runner.ts +639 -0
- package/src/types.ts +505 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/assertions.ts"],"names":[],"mappings":";;;;AAWO,IAAM,cAAA,GAAN,cAA6B,KAAA,CAAM;AAAA,EACxC,WAAA,CACE,OAAA,EACO,QAAA,EACA,MAAA,EACA,QAAA,EACP;AACA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A,IAAW,4CAA4C,CAAA;AAAA,EAClF;AAAA,EAEA,cAAA,CAAe,WAAmB,OAAA,EAAwB;AAExD,IAAA,MAAM,IAAI,cAAA,CAAe,OAAA,IAAW,yCAAyC,CAAA;AAAA,EAC/E;AAAA,EAEQ,YAAA,CAAa,QAAa,QAAA,EAAwB;AACxD,IAAA,IAAI,OAAO,aAAa,QAAA,EAAU;AAChC,MAAA,OAAO,OAAO,OAAA,KAAY,QAAA;AAAA,IAC5B;AACA,IAAA,IAAI,oBAAoB,MAAA,EAAQ;AAC9B,MAAA,OAAO,QAAA,CAAS,IAAA,CAAK,MAAA,CAAO,OAAO,CAAA;AAAA,IACrC;AACA,IAAA,IAAI,OAAO,aAAa,UAAA,EAAY;AAClC,MAAA,OAAO,MAAA,YAAkB,QAAA;AAAA,IAC3B;AACA,IAAA,OAAO,MAAA,KAAW,QAAA;AAAA,EACpB;AACF,CAAA;AAKO,SAAS,eAAA,GAA6B;AAC3C,EAAA,OAAO,IAAI,aAAA,EAAc;AAC3B","file":"assertions.mjs","sourcesContent":["/**\n * Assertion Library\n * Comprehensive assertion and expectation framework for HyperFixi testing\n */\n\nimport { diffLines } from 'diff';\nimport type { ExpectAPI, ExpectMatcher, AssertAPI } from './types';\n\n/**\n * Assertion error class\n */\nexport class AssertionError extends Error {\n constructor(\n message: string,\n public expected?: any,\n public actual?: any,\n public operator?: string\n ) {\n super(message);\n this.name = 'AssertionError';\n }\n}\n\n/**\n * Deep equality comparison\n */\nfunction deepEqual(actual: any, expected: any): boolean {\n if (actual === expected) return true;\n\n if (actual == null || expected == null) return actual === expected;\n\n if (typeof actual !== typeof expected) return false;\n\n if (actual instanceof Date && expected instanceof Date) {\n return actual.getTime() === expected.getTime();\n }\n\n if (actual instanceof RegExp && expected instanceof RegExp) {\n return actual.toString() === expected.toString();\n }\n\n if (Array.isArray(actual) && Array.isArray(expected)) {\n if (actual.length !== expected.length) return false;\n for (let i = 0; i < actual.length; i++) {\n if (!deepEqual(actual[i], expected[i])) return false;\n }\n return true;\n }\n\n if (typeof actual === 'object' && typeof expected === 'object') {\n const actualKeys = Object.keys(actual);\n const expectedKeys = Object.keys(expected);\n\n if (actualKeys.length !== expectedKeys.length) return false;\n\n for (const key of actualKeys) {\n if (!expectedKeys.includes(key)) return false;\n if (!deepEqual(actual[key], expected[key])) return false;\n }\n\n return true;\n }\n\n return false;\n}\n\n/**\n * Generate diff between actual and expected values\n */\nfunction generateDiff(actual: any, expected: any): string {\n const actualStr = typeof actual === 'string' ? actual : JSON.stringify(actual, null, 2);\n const expectedStr = typeof expected === 'string' ? expected : JSON.stringify(expected, null, 2);\n\n const diff = diffLines(expectedStr, actualStr);\n\n return diff\n .map(part => {\n const prefix = part.added ? '+' : part.removed ? '-' : ' ';\n return part.value\n .split('\\n')\n .map(line => `${prefix} ${line}`)\n .join('\\n');\n })\n .join('\\n');\n}\n\n/**\n * Check if element is in the document\n */\nfunction isInDocument(element: Element): boolean {\n if (typeof document === 'undefined') return false;\n return document.contains(element);\n}\n\n/**\n * Check if element is visible\n */\nfunction isVisible(element: Element): boolean {\n if (!isInDocument(element)) return false;\n\n const style = window.getComputedStyle(element);\n return style.display !== 'none' && style.visibility !== 'hidden' && style.opacity !== '0';\n}\n\n/**\n * ExpectMatcher implementation\n */\nclass ExpectMatcherImpl implements ExpectMatcher {\n constructor(\n private actual: any,\n private isNot: boolean = false\n ) {}\n\n get not(): ExpectMatcher {\n return new ExpectMatcherImpl(this.actual, !this.isNot);\n }\n\n get resolves(): ExpectMatcher {\n if (!this.isPromise(this.actual)) {\n throw new AssertionError('Expected value to be a Promise');\n }\n\n // Return a new matcher that operates on the resolved value\n return new ExpectMatcherImpl(\n this.actual.then((value: any) => value),\n this.isNot\n );\n }\n\n get rejects(): ExpectMatcher {\n if (!this.isPromise(this.actual)) {\n throw new AssertionError('Expected value to be a Promise');\n }\n\n // Return a new matcher that expects the promise to reject\n return new ExpectMatcherImpl(\n this.actual.then(\n (value: any) => {\n throw new Error('Promise did not reject');\n },\n (error: any) => error\n ),\n this.isNot\n );\n }\n\n toBe(expected: any): void {\n const passed = this.actual === expected;\n this.assert(\n passed,\n 'toBe',\n expected,\n `Expected ${this.format(this.actual)} to be ${this.format(expected)}`\n );\n }\n\n toEqual(expected: any): void {\n const passed = deepEqual(this.actual, expected);\n this.assert(\n passed,\n 'toEqual',\n expected,\n `Expected ${this.format(this.actual)} to equal ${this.format(expected)}`\n );\n }\n\n toStrictEqual(expected: any): void {\n const passed = this.actual === expected && deepEqual(this.actual, expected);\n this.assert(\n passed,\n 'toStrictEqual',\n expected,\n `Expected ${this.format(this.actual)} to strictly equal ${this.format(expected)}`\n );\n }\n\n toBeTruthy(): void {\n const passed = Boolean(this.actual);\n this.assert(passed, 'toBeTruthy', true, `Expected ${this.format(this.actual)} to be truthy`);\n }\n\n toBeFalsy(): void {\n const passed = !Boolean(this.actual);\n this.assert(passed, 'toBeFalsy', false, `Expected ${this.format(this.actual)} to be falsy`);\n }\n\n toBeNull(): void {\n const passed = this.actual === null;\n this.assert(passed, 'toBeNull', null, `Expected ${this.format(this.actual)} to be null`);\n }\n\n toBeUndefined(): void {\n const passed = this.actual === undefined;\n this.assert(\n passed,\n 'toBeUndefined',\n undefined,\n `Expected ${this.format(this.actual)} to be undefined`\n );\n }\n\n toBeDefined(): void {\n const passed = this.actual !== undefined;\n this.assert(\n passed,\n 'toBeDefined',\n 'defined',\n `Expected ${this.format(this.actual)} to be defined`\n );\n }\n\n toBeNaN(): void {\n const passed = Number.isNaN(this.actual);\n this.assert(passed, 'toBeNaN', NaN, `Expected ${this.format(this.actual)} to be NaN`);\n }\n\n toBeInstanceOf(constructor: any): void {\n const passed = this.actual instanceof constructor;\n this.assert(\n passed,\n 'toBeInstanceOf',\n constructor,\n `Expected ${this.format(this.actual)} to be instance of ${constructor.name}`\n );\n }\n\n toBeCloseTo(expected: number, precision: number = 2): void {\n if (typeof this.actual !== 'number' || typeof expected !== 'number') {\n throw new AssertionError('Expected both values to be numbers');\n }\n\n const diff = Math.abs(this.actual - expected);\n const passed = diff < Math.pow(10, -precision) / 2;\n this.assert(\n passed,\n 'toBeCloseTo',\n expected,\n `Expected ${this.actual} to be close to ${expected} (precision: ${precision})`\n );\n }\n\n toMatch(expected: string | RegExp): void {\n if (typeof this.actual !== 'string') {\n throw new AssertionError('Expected value to be a string');\n }\n\n const regex = typeof expected === 'string' ? new RegExp(expected) : expected;\n const passed = regex.test(this.actual);\n this.assert(passed, 'toMatch', expected, `Expected \"${this.actual}\" to match ${expected}`);\n }\n\n toContain(expected: any): void {\n let passed = false;\n\n if (typeof this.actual === 'string' && typeof expected === 'string') {\n passed = this.actual.includes(expected);\n } else if (Array.isArray(this.actual)) {\n passed = this.actual.includes(expected);\n } else if (this.actual && typeof this.actual.has === 'function') {\n passed = this.actual.has(expected);\n }\n\n this.assert(\n passed,\n 'toContain',\n expected,\n `Expected ${this.format(this.actual)} to contain ${this.format(expected)}`\n );\n }\n\n toHaveLength(expected: number): void {\n if (this.actual == null || typeof this.actual.length !== 'number') {\n throw new AssertionError('Expected value to have a length property');\n }\n\n const passed = this.actual.length === expected;\n this.assert(\n passed,\n 'toHaveLength',\n expected,\n `Expected length ${this.actual.length} to be ${expected}`\n );\n }\n\n toContainEqual(expected: any): void {\n if (!Array.isArray(this.actual)) {\n throw new AssertionError('Expected value to be an array');\n }\n\n const passed = this.actual.some(item => deepEqual(item, expected));\n this.assert(\n passed,\n 'toContainEqual',\n expected,\n `Expected array to contain equal to ${this.format(expected)}`\n );\n }\n\n toHaveProperty(path: string, value?: any): void {\n const keys = path.split('.');\n let current = this.actual;\n\n for (const key of keys) {\n if (current == null || !Object.prototype.hasOwnProperty.call(current, key)) {\n this.assert(false, 'toHaveProperty', path, `Expected object to have property \"${path}\"`);\n return;\n }\n current = current[key];\n }\n\n if (value !== undefined) {\n const passed = deepEqual(current, value);\n this.assert(\n passed,\n 'toHaveProperty',\n value,\n `Expected property \"${path}\" to have value ${this.format(value)}, got ${this.format(current)}`\n );\n } else {\n this.assert(true, 'toHaveProperty', path, '');\n }\n }\n\n toMatchObject(expected: object): void {\n if (typeof this.actual !== 'object' || this.actual === null) {\n throw new AssertionError('Expected value to be an object');\n }\n\n const passed = Object.keys(expected).every(key =>\n deepEqual(this.actual[key], (expected as any)[key])\n );\n\n this.assert(\n passed,\n 'toMatchObject',\n expected,\n `Expected object to match ${this.format(expected)}`\n );\n }\n\n // DOM-specific matchers\n toBeInTheDocument(): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n const passed = isInDocument(this.actual);\n this.assert(\n passed,\n 'toBeInTheDocument',\n 'in document',\n 'Expected element to be in the document'\n );\n }\n\n toBeVisible(): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n const passed = isVisible(this.actual);\n this.assert(passed, 'toBeVisible', 'visible', 'Expected element to be visible');\n }\n\n toBeDisabled(): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n const passed = (this.actual as any).disabled === true || this.actual.hasAttribute('disabled');\n this.assert(passed, 'toBeDisabled', 'disabled', 'Expected element to be disabled');\n }\n\n toBeEnabled(): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n const passed = (this.actual as any).disabled !== true && !this.actual.hasAttribute('disabled');\n this.assert(passed, 'toBeEnabled', 'enabled', 'Expected element to be enabled');\n }\n\n toBeChecked(): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n const passed = (this.actual as any).checked === true;\n this.assert(passed, 'toBeChecked', 'checked', 'Expected element to be checked');\n }\n\n toHaveClass(className: string): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n const passed = this.actual.classList.contains(className);\n this.assert(passed, 'toHaveClass', className, `Expected element to have class \"${className}\"`);\n }\n\n toHaveAttribute(name: string, value?: string): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n if (value === undefined) {\n const passed = this.actual.hasAttribute(name);\n this.assert(\n passed,\n 'toHaveAttribute',\n `attribute \"${name}\"`,\n `Expected element to have attribute \"${name}\"`\n );\n } else {\n const passed = this.actual.getAttribute(name) === value;\n this.assert(\n passed,\n 'toHaveAttribute',\n `${name}=\"${value}\"`,\n `Expected element to have attribute \"${name}\" with value \"${value}\"`\n );\n }\n }\n\n toHaveTextContent(text: string | RegExp): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n const textContent = this.actual.textContent || '';\n const passed = typeof text === 'string' ? textContent === text : text.test(textContent);\n\n this.assert(\n passed,\n 'toHaveTextContent',\n text,\n `Expected element to have text content \"${text}\"`\n );\n }\n\n toHaveValue(value: any): void {\n if (!(this.actual instanceof Element)) {\n throw new AssertionError('Expected value to be a DOM element');\n }\n\n const actualValue = (this.actual as any).value;\n const passed = actualValue === value;\n this.assert(\n passed,\n 'toHaveValue',\n value,\n `Expected element to have value \"${value}\", got \"${actualValue}\"`\n );\n }\n\n // HyperScript-specific matchers\n toHaveCompiledScript(): void {\n // Implementation would depend on HyperFixi API\n const passed = this.actual && typeof this.actual._hyperscript !== 'undefined';\n this.assert(\n passed,\n 'toHaveCompiledScript',\n 'compiled script',\n 'Expected element to have compiled hyperscript'\n );\n }\n\n toHaveExecutedScript(): void {\n // Implementation would depend on HyperFixi API\n const passed = this.actual && this.actual._hyperscriptExecuted === true;\n this.assert(\n passed,\n 'toHaveExecutedScript',\n 'executed script',\n 'Expected hyperscript to have executed'\n );\n }\n\n toHaveTriggeredEvent(eventType: string): void {\n // Implementation would depend on event tracking\n const passed =\n this.actual &&\n this.actual._triggeredEvents &&\n this.actual._triggeredEvents.includes(eventType);\n this.assert(\n passed,\n 'toHaveTriggeredEvent',\n eventType,\n `Expected event \"${eventType}\" to have been triggered`\n );\n }\n\n toHaveUpdatedElement(): void {\n // Implementation would depend on DOM change tracking\n const passed = this.actual && this.actual._wasUpdated === true;\n this.assert(\n passed,\n 'toHaveUpdatedElement',\n 'updated element',\n 'Expected element to have been updated'\n );\n }\n\n private assert(passed: boolean, operator: string, expected: any, message: string): void {\n if (this.isNot) {\n passed = !passed;\n message = message.replace('Expected', 'Expected NOT');\n }\n\n if (!passed) {\n const error = new AssertionError(message, expected, this.actual, operator);\n\n if (typeof this.actual === 'object' && typeof expected === 'object') {\n error.message += '\\n\\nDiff:\\n' + generateDiff(this.actual, expected);\n }\n\n throw error;\n }\n }\n\n private format(value: any): string {\n if (value === null) return 'null';\n if (value === undefined) return 'undefined';\n if (typeof value === 'string') return `\"${value}\"`;\n if (typeof value === 'function') return value.name || 'function';\n if (value instanceof Date) return value.toISOString();\n if (value instanceof RegExp) return value.toString();\n if (Array.isArray(value)) return `[${value.map(v => this.format(v)).join(', ')}]`;\n if (typeof value === 'object') return JSON.stringify(value);\n return String(value);\n }\n\n private isPromise(value: any): boolean {\n return value && typeof value.then === 'function';\n }\n}\n\n/**\n * Create expect API\n */\nexport function createExpectAPI(): ExpectAPI {\n return function expect(actual: any): ExpectMatcher {\n return new ExpectMatcherImpl(actual);\n };\n}\n\n/**\n * Assert API implementation\n */\nclass AssertAPIImpl implements AssertAPI {\n ok(value: any, message?: string): void {\n if (!value) {\n throw new AssertionError(message || `Expected ${value} to be truthy`);\n }\n }\n\n equal(actual: any, expected: any, message?: string): void {\n if (actual != expected) {\n throw new AssertionError(\n message || `Expected ${actual} to equal ${expected}`,\n expected,\n actual,\n 'equal'\n );\n }\n }\n\n strictEqual(actual: any, expected: any, message?: string): void {\n if (actual !== expected) {\n throw new AssertionError(\n message || `Expected ${actual} to strictly equal ${expected}`,\n expected,\n actual,\n 'strictEqual'\n );\n }\n }\n\n notEqual(actual: any, expected: any, message?: string): void {\n if (actual == expected) {\n throw new AssertionError(\n message || `Expected ${actual} to not equal ${expected}`,\n expected,\n actual,\n 'notEqual'\n );\n }\n }\n\n notStrictEqual(actual: any, expected: any, message?: string): void {\n if (actual === expected) {\n throw new AssertionError(\n message || `Expected ${actual} to not strictly equal ${expected}`,\n expected,\n actual,\n 'notStrictEqual'\n );\n }\n }\n\n throws(fn: () => void, error?: any, message?: string): void {\n let thrown = false;\n let actualError: any;\n\n try {\n fn();\n } catch (e) {\n thrown = true;\n actualError = e;\n }\n\n if (!thrown) {\n throw new AssertionError(message || 'Expected function to throw');\n }\n\n if (error && !this.matchesError(actualError, error)) {\n throw new AssertionError(\n message || `Expected function to throw ${error}, but got ${actualError}`,\n error,\n actualError,\n 'throws'\n );\n }\n }\n\n doesNotThrow(fn: () => void, message?: string): void {\n try {\n fn();\n } catch (e) {\n throw new AssertionError(\n message || `Expected function to not throw, but got: ${e}`,\n 'no error',\n e,\n 'doesNotThrow'\n );\n }\n }\n\n ifError(value: any): void {\n if (value) {\n throw value;\n }\n }\n\n async rejects(promise: Promise<any>, error?: any, message?: string): Promise<void> {\n let rejected = false;\n let actualError: any;\n\n try {\n await promise;\n } catch (e) {\n rejected = true;\n actualError = e;\n }\n\n if (!rejected) {\n throw new AssertionError(message || 'Expected promise to reject');\n }\n\n if (error && !this.matchesError(actualError, error)) {\n throw new AssertionError(\n message || `Expected promise to reject with ${error}, but got ${actualError}`,\n error,\n actualError,\n 'rejects'\n );\n }\n }\n\n async doesNotReject(promise: Promise<any>, message?: string): Promise<void> {\n try {\n await promise;\n } catch (e) {\n throw new AssertionError(\n message || `Expected promise to not reject, but got: ${e}`,\n 'no error',\n e,\n 'doesNotReject'\n );\n }\n }\n\n elementExists(selector: string, message?: string): void {\n if (typeof document === 'undefined') {\n throw new AssertionError('DOM not available');\n }\n\n const element = document.querySelector(selector);\n if (!element) {\n throw new AssertionError(message || `Expected element with selector \"${selector}\" to exist`);\n }\n }\n\n elementVisible(selector: string, message?: string): void {\n if (typeof document === 'undefined') {\n throw new AssertionError('DOM not available');\n }\n\n const element = document.querySelector(selector);\n if (!element) {\n throw new AssertionError(`Element with selector \"${selector}\" does not exist`);\n }\n\n if (!isVisible(element)) {\n throw new AssertionError(\n message || `Expected element with selector \"${selector}\" to be visible`\n );\n }\n }\n\n elementHasClass(selector: string, className: string, message?: string): void {\n if (typeof document === 'undefined') {\n throw new AssertionError('DOM not available');\n }\n\n const element = document.querySelector(selector);\n if (!element) {\n throw new AssertionError(`Element with selector \"${selector}\" does not exist`);\n }\n\n if (!element.classList.contains(className)) {\n throw new AssertionError(\n message || `Expected element with selector \"${selector}\" to have class \"${className}\"`\n );\n }\n }\n\n elementHasText(selector: string, text: string, message?: string): void {\n if (typeof document === 'undefined') {\n throw new AssertionError('DOM not available');\n }\n\n const element = document.querySelector(selector);\n if (!element) {\n throw new AssertionError(`Element with selector \"${selector}\" does not exist`);\n }\n\n if (element.textContent !== text) {\n throw new AssertionError(\n message || `Expected element with selector \"${selector}\" to have text \"${text}\"`\n );\n }\n }\n\n scriptCompiled(script: string, message?: string): void {\n // Implementation would depend on HyperFixi API\n throw new AssertionError(message || 'Script compilation assertion not implemented');\n }\n\n scriptExecuted(script: string, message?: string): void {\n // Implementation would depend on HyperFixi API\n throw new AssertionError(message || 'Script execution assertion not implemented');\n }\n\n eventTriggered(eventType: string, message?: string): void {\n // Implementation would depend on event tracking\n throw new AssertionError(message || 'Event trigger assertion not implemented');\n }\n\n private matchesError(actual: any, expected: any): boolean {\n if (typeof expected === 'string') {\n return actual.message === expected;\n }\n if (expected instanceof RegExp) {\n return expected.test(actual.message);\n }\n if (typeof expected === 'function') {\n return actual instanceof expected;\n }\n return actual === expected;\n }\n}\n\n/**\n * Create assert API\n */\nexport function createAssertAPI(): AssertAPI {\n return new AssertAPIImpl();\n}\n"]}
|
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,246 @@
|
|
|
1
|
+
import { T as TestRunner, a as TestSuite, b as TestConfig, c as TestResult, d as TestCase, e as TestContext, P as PerformanceMetrics, f as TestFunction, M as MockFunction, S as SpyFunction, g as PageObject, h as TestEnvironment, B as BrowserType } from './assertions-BImuwZsB.mjs';
|
|
2
|
+
export { F as AccessibilityCheckResult, z as AccessibilityIncomplete, D as AccessibilityNode, y as AccessibilityPass, w as AccessibilityResult, x as AccessibilityViolation, p as AssertAPI, A as AssertionError, n as BrowserTestOptions, C as CoverageData, v as E2EAction, u as E2EStep, E as ExpectAPI, o as ExpectMatcher, r as TestDataProvider, t as TestDiscoveryOptions, l as TestError, s as TestFixture, m as TestLog, q as TestReporter, k as TestStatus, V as VisualTestConfig, j as createAssertAPI, i as createExpectAPI } from './assertions-BImuwZsB.mjs';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Test Runner
|
|
6
|
+
* Core test execution engine with multi-environment support
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Core test runner implementation
|
|
11
|
+
*/
|
|
12
|
+
declare class CoreTestRunner implements TestRunner {
|
|
13
|
+
private executionContext;
|
|
14
|
+
/**
|
|
15
|
+
* Run all test suites
|
|
16
|
+
*/
|
|
17
|
+
run(suites: TestSuite[], config: TestConfig): Promise<TestResult[]>;
|
|
18
|
+
/**
|
|
19
|
+
* Run a single test suite
|
|
20
|
+
*/
|
|
21
|
+
runSuite(suite: TestSuite, config: TestConfig): Promise<TestResult[]>;
|
|
22
|
+
/**
|
|
23
|
+
* Run a single test
|
|
24
|
+
*/
|
|
25
|
+
runTest(test: TestCase, context: TestContext): Promise<TestResult>;
|
|
26
|
+
/**
|
|
27
|
+
* Setup execution context
|
|
28
|
+
*/
|
|
29
|
+
private setupExecutionContext;
|
|
30
|
+
/**
|
|
31
|
+
* Setup JSDOM context
|
|
32
|
+
*/
|
|
33
|
+
private setupJSDOMContext;
|
|
34
|
+
/**
|
|
35
|
+
* Setup browser context (Playwright)
|
|
36
|
+
*/
|
|
37
|
+
private setupBrowserContext;
|
|
38
|
+
/**
|
|
39
|
+
* Setup Puppeteer context
|
|
40
|
+
*/
|
|
41
|
+
private setupPuppeteerContext;
|
|
42
|
+
/**
|
|
43
|
+
* Create test context
|
|
44
|
+
*/
|
|
45
|
+
private createTestContext;
|
|
46
|
+
/**
|
|
47
|
+
* Setup test fixtures
|
|
48
|
+
*/
|
|
49
|
+
private setupTestFixtures;
|
|
50
|
+
/**
|
|
51
|
+
* Cleanup test fixtures
|
|
52
|
+
*/
|
|
53
|
+
private cleanupTestFixtures;
|
|
54
|
+
/**
|
|
55
|
+
* Run beforeEach hooks
|
|
56
|
+
*/
|
|
57
|
+
private runBeforeEachHooks;
|
|
58
|
+
/**
|
|
59
|
+
* Run afterEach hooks
|
|
60
|
+
*/
|
|
61
|
+
private runAfterEachHooks;
|
|
62
|
+
/**
|
|
63
|
+
* Run setup files
|
|
64
|
+
*/
|
|
65
|
+
private runSetupFiles;
|
|
66
|
+
/**
|
|
67
|
+
* Run teardown files
|
|
68
|
+
*/
|
|
69
|
+
private runTeardownFiles;
|
|
70
|
+
/**
|
|
71
|
+
* Take screenshot
|
|
72
|
+
*/
|
|
73
|
+
private takeScreenshot;
|
|
74
|
+
/**
|
|
75
|
+
* Format error for test result
|
|
76
|
+
*/
|
|
77
|
+
private formatError;
|
|
78
|
+
/**
|
|
79
|
+
* Create skipped test result
|
|
80
|
+
*/
|
|
81
|
+
private createSkippedResult;
|
|
82
|
+
/**
|
|
83
|
+
* Cleanup execution context
|
|
84
|
+
*/
|
|
85
|
+
private cleanupExecutionContext;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Parallel test runner
|
|
89
|
+
*/
|
|
90
|
+
declare class ParallelTestRunner extends CoreTestRunner {
|
|
91
|
+
/**
|
|
92
|
+
* Run test suites in parallel
|
|
93
|
+
*/
|
|
94
|
+
run(suites: TestSuite[], config: TestConfig): Promise<TestResult[]>;
|
|
95
|
+
/**
|
|
96
|
+
* Split suites into chunks for parallel execution
|
|
97
|
+
*/
|
|
98
|
+
private chunkSuites;
|
|
99
|
+
/**
|
|
100
|
+
* Run a worker with assigned test suites
|
|
101
|
+
*/
|
|
102
|
+
private runWorker;
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* Create test runner based on configuration
|
|
106
|
+
*/
|
|
107
|
+
declare function createTestRunner(config: TestConfig): TestRunner;
|
|
108
|
+
/**
|
|
109
|
+
* Run performance measurements
|
|
110
|
+
*/
|
|
111
|
+
declare function measurePerformance(page: any, testFn: () => Promise<void>): Promise<PerformanceMetrics>;
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Default test configuration
|
|
115
|
+
*/
|
|
116
|
+
declare const DEFAULT_CONFIG: TestConfig;
|
|
117
|
+
/**
|
|
118
|
+
* Create a test suite
|
|
119
|
+
*/
|
|
120
|
+
declare function describe(name: string, fn: () => void): void;
|
|
121
|
+
declare function describe(name: string, options: Partial<TestSuite>, fn: () => void): void;
|
|
122
|
+
/**
|
|
123
|
+
* Create a test case
|
|
124
|
+
*/
|
|
125
|
+
declare function it(name: string, fn: TestFunction): void;
|
|
126
|
+
declare function it(name: string, options: Partial<TestCase>, fn: TestFunction): void;
|
|
127
|
+
/**
|
|
128
|
+
* Alias for it()
|
|
129
|
+
*/
|
|
130
|
+
declare const test: typeof it;
|
|
131
|
+
/**
|
|
132
|
+
* Skip a test suite
|
|
133
|
+
*/
|
|
134
|
+
declare function describe_skip(name: string, fn: () => void): void;
|
|
135
|
+
/**
|
|
136
|
+
* Skip a test case
|
|
137
|
+
*/
|
|
138
|
+
declare function it_skip(name: string, fn: TestFunction): void;
|
|
139
|
+
/**
|
|
140
|
+
* Focus on a test suite (only run this suite)
|
|
141
|
+
*/
|
|
142
|
+
declare function describe_only(name: string, fn: () => void): void;
|
|
143
|
+
/**
|
|
144
|
+
* Focus on a test case (only run this test)
|
|
145
|
+
*/
|
|
146
|
+
declare function it_only(name: string, fn: TestFunction): void;
|
|
147
|
+
/**
|
|
148
|
+
* Setup function to run before all tests in a suite
|
|
149
|
+
*/
|
|
150
|
+
declare function beforeAll(fn: () => Promise<void> | void): void;
|
|
151
|
+
/**
|
|
152
|
+
* Teardown function to run after all tests in a suite
|
|
153
|
+
*/
|
|
154
|
+
declare function afterAll(fn: () => Promise<void> | void): void;
|
|
155
|
+
/**
|
|
156
|
+
* Setup function to run before each test in a suite
|
|
157
|
+
*/
|
|
158
|
+
declare function beforeEach(fn: () => Promise<void> | void): void;
|
|
159
|
+
/**
|
|
160
|
+
* Teardown function to run after each test in a suite
|
|
161
|
+
*/
|
|
162
|
+
declare function afterEach(fn: () => Promise<void> | void): void;
|
|
163
|
+
/**
|
|
164
|
+
* Run all registered test suites
|
|
165
|
+
*/
|
|
166
|
+
declare function runTests(config?: Partial<TestConfig>): Promise<TestResult[]>;
|
|
167
|
+
/**
|
|
168
|
+
* Clear all registered test suites
|
|
169
|
+
*/
|
|
170
|
+
declare function clearTests(): void;
|
|
171
|
+
/**
|
|
172
|
+
* Create a test fixture
|
|
173
|
+
*/
|
|
174
|
+
declare function fixture<T>(name: string, setup: () => T | Promise<T>, teardown?: (fixture: T) => void | Promise<void>): {
|
|
175
|
+
name: string;
|
|
176
|
+
create(): Promise<T>;
|
|
177
|
+
destroy(instance: T): Promise<void>;
|
|
178
|
+
};
|
|
179
|
+
/**
|
|
180
|
+
* Create a mock function
|
|
181
|
+
*/
|
|
182
|
+
declare function createMock<T extends (...args: any[]) => any>(implementation?: T): MockFunction;
|
|
183
|
+
/**
|
|
184
|
+
* Create a spy function
|
|
185
|
+
*/
|
|
186
|
+
declare function createSpy<T extends (...args: any[]) => any>(target: any, method: string): SpyFunction;
|
|
187
|
+
/**
|
|
188
|
+
* Wait for a condition to be true
|
|
189
|
+
*/
|
|
190
|
+
declare function waitFor(condition: () => boolean | Promise<boolean>, options?: {
|
|
191
|
+
timeout?: number;
|
|
192
|
+
interval?: number;
|
|
193
|
+
}): Promise<void>;
|
|
194
|
+
/**
|
|
195
|
+
* Create a page object for E2E testing
|
|
196
|
+
*/
|
|
197
|
+
declare function createPageObject(definition: PageObject): {
|
|
198
|
+
goto(page: any): Promise<void>;
|
|
199
|
+
element(name: string): string;
|
|
200
|
+
action(page: any, name: string, ...args: any[]): Promise<any>;
|
|
201
|
+
assert(page: any, name: string, ...args: any[]): Promise<void>;
|
|
202
|
+
name: string;
|
|
203
|
+
url?: string;
|
|
204
|
+
selectors: Record<string, string>;
|
|
205
|
+
actions: Record<string, (...args: any[]) => Promise<any>>;
|
|
206
|
+
assertions: Record<string, (...args: any[]) => Promise<void>>;
|
|
207
|
+
};
|
|
208
|
+
/**
|
|
209
|
+
* Integration with LokaScript core for behavior testing
|
|
210
|
+
*/
|
|
211
|
+
declare function createLokaScriptTestContext(hyperfixi: any): {
|
|
212
|
+
compileAndTest(script: string, element: Element, event?: string): Promise<any>;
|
|
213
|
+
testCompilation(script: string): Promise<{
|
|
214
|
+
success: boolean;
|
|
215
|
+
result: any;
|
|
216
|
+
error?: never;
|
|
217
|
+
} | {
|
|
218
|
+
success: boolean;
|
|
219
|
+
error: unknown;
|
|
220
|
+
result?: never;
|
|
221
|
+
}>;
|
|
222
|
+
testExecution(script: string, element: Element, eventType?: string): Promise<{
|
|
223
|
+
executed: boolean;
|
|
224
|
+
compiled: any;
|
|
225
|
+
}>;
|
|
226
|
+
};
|
|
227
|
+
/**
|
|
228
|
+
* Quick start function for basic testing setup
|
|
229
|
+
*/
|
|
230
|
+
declare function quickStartTesting(options?: {
|
|
231
|
+
environment?: TestEnvironment;
|
|
232
|
+
browser?: BrowserType;
|
|
233
|
+
headless?: boolean;
|
|
234
|
+
baseURL?: string;
|
|
235
|
+
testFiles?: string[];
|
|
236
|
+
}): Promise<{
|
|
237
|
+
config: Partial<TestConfig>;
|
|
238
|
+
run: () => Promise<TestResult[]>;
|
|
239
|
+
clear: typeof clearTests;
|
|
240
|
+
}>;
|
|
241
|
+
/**
|
|
242
|
+
* Version information
|
|
243
|
+
*/
|
|
244
|
+
declare const VERSION = "0.1.0";
|
|
245
|
+
|
|
246
|
+
export { BrowserType, CoreTestRunner, DEFAULT_CONFIG, MockFunction, PageObject, ParallelTestRunner, PerformanceMetrics, SpyFunction, TestCase, TestConfig, TestContext, TestEnvironment, TestFunction, TestResult, TestRunner, TestSuite, VERSION, afterAll, afterEach, beforeAll, beforeEach, clearTests, createLokaScriptTestContext, createMock, createPageObject, createSpy, createTestRunner, describe, describe_only, describe_skip, fixture, it, it_only, it_skip, measurePerformance, quickStartTesting, runTests, test, waitFor };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,246 @@
|
|
|
1
|
+
import { T as TestRunner, a as TestSuite, b as TestConfig, c as TestResult, d as TestCase, e as TestContext, P as PerformanceMetrics, f as TestFunction, M as MockFunction, S as SpyFunction, g as PageObject, h as TestEnvironment, B as BrowserType } from './assertions-BImuwZsB.js';
|
|
2
|
+
export { F as AccessibilityCheckResult, z as AccessibilityIncomplete, D as AccessibilityNode, y as AccessibilityPass, w as AccessibilityResult, x as AccessibilityViolation, p as AssertAPI, A as AssertionError, n as BrowserTestOptions, C as CoverageData, v as E2EAction, u as E2EStep, E as ExpectAPI, o as ExpectMatcher, r as TestDataProvider, t as TestDiscoveryOptions, l as TestError, s as TestFixture, m as TestLog, q as TestReporter, k as TestStatus, V as VisualTestConfig, j as createAssertAPI, i as createExpectAPI } from './assertions-BImuwZsB.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Test Runner
|
|
6
|
+
* Core test execution engine with multi-environment support
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Core test runner implementation
|
|
11
|
+
*/
|
|
12
|
+
declare class CoreTestRunner implements TestRunner {
|
|
13
|
+
private executionContext;
|
|
14
|
+
/**
|
|
15
|
+
* Run all test suites
|
|
16
|
+
*/
|
|
17
|
+
run(suites: TestSuite[], config: TestConfig): Promise<TestResult[]>;
|
|
18
|
+
/**
|
|
19
|
+
* Run a single test suite
|
|
20
|
+
*/
|
|
21
|
+
runSuite(suite: TestSuite, config: TestConfig): Promise<TestResult[]>;
|
|
22
|
+
/**
|
|
23
|
+
* Run a single test
|
|
24
|
+
*/
|
|
25
|
+
runTest(test: TestCase, context: TestContext): Promise<TestResult>;
|
|
26
|
+
/**
|
|
27
|
+
* Setup execution context
|
|
28
|
+
*/
|
|
29
|
+
private setupExecutionContext;
|
|
30
|
+
/**
|
|
31
|
+
* Setup JSDOM context
|
|
32
|
+
*/
|
|
33
|
+
private setupJSDOMContext;
|
|
34
|
+
/**
|
|
35
|
+
* Setup browser context (Playwright)
|
|
36
|
+
*/
|
|
37
|
+
private setupBrowserContext;
|
|
38
|
+
/**
|
|
39
|
+
* Setup Puppeteer context
|
|
40
|
+
*/
|
|
41
|
+
private setupPuppeteerContext;
|
|
42
|
+
/**
|
|
43
|
+
* Create test context
|
|
44
|
+
*/
|
|
45
|
+
private createTestContext;
|
|
46
|
+
/**
|
|
47
|
+
* Setup test fixtures
|
|
48
|
+
*/
|
|
49
|
+
private setupTestFixtures;
|
|
50
|
+
/**
|
|
51
|
+
* Cleanup test fixtures
|
|
52
|
+
*/
|
|
53
|
+
private cleanupTestFixtures;
|
|
54
|
+
/**
|
|
55
|
+
* Run beforeEach hooks
|
|
56
|
+
*/
|
|
57
|
+
private runBeforeEachHooks;
|
|
58
|
+
/**
|
|
59
|
+
* Run afterEach hooks
|
|
60
|
+
*/
|
|
61
|
+
private runAfterEachHooks;
|
|
62
|
+
/**
|
|
63
|
+
* Run setup files
|
|
64
|
+
*/
|
|
65
|
+
private runSetupFiles;
|
|
66
|
+
/**
|
|
67
|
+
* Run teardown files
|
|
68
|
+
*/
|
|
69
|
+
private runTeardownFiles;
|
|
70
|
+
/**
|
|
71
|
+
* Take screenshot
|
|
72
|
+
*/
|
|
73
|
+
private takeScreenshot;
|
|
74
|
+
/**
|
|
75
|
+
* Format error for test result
|
|
76
|
+
*/
|
|
77
|
+
private formatError;
|
|
78
|
+
/**
|
|
79
|
+
* Create skipped test result
|
|
80
|
+
*/
|
|
81
|
+
private createSkippedResult;
|
|
82
|
+
/**
|
|
83
|
+
* Cleanup execution context
|
|
84
|
+
*/
|
|
85
|
+
private cleanupExecutionContext;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Parallel test runner
|
|
89
|
+
*/
|
|
90
|
+
declare class ParallelTestRunner extends CoreTestRunner {
|
|
91
|
+
/**
|
|
92
|
+
* Run test suites in parallel
|
|
93
|
+
*/
|
|
94
|
+
run(suites: TestSuite[], config: TestConfig): Promise<TestResult[]>;
|
|
95
|
+
/**
|
|
96
|
+
* Split suites into chunks for parallel execution
|
|
97
|
+
*/
|
|
98
|
+
private chunkSuites;
|
|
99
|
+
/**
|
|
100
|
+
* Run a worker with assigned test suites
|
|
101
|
+
*/
|
|
102
|
+
private runWorker;
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* Create test runner based on configuration
|
|
106
|
+
*/
|
|
107
|
+
declare function createTestRunner(config: TestConfig): TestRunner;
|
|
108
|
+
/**
|
|
109
|
+
* Run performance measurements
|
|
110
|
+
*/
|
|
111
|
+
declare function measurePerformance(page: any, testFn: () => Promise<void>): Promise<PerformanceMetrics>;
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Default test configuration
|
|
115
|
+
*/
|
|
116
|
+
declare const DEFAULT_CONFIG: TestConfig;
|
|
117
|
+
/**
|
|
118
|
+
* Create a test suite
|
|
119
|
+
*/
|
|
120
|
+
declare function describe(name: string, fn: () => void): void;
|
|
121
|
+
declare function describe(name: string, options: Partial<TestSuite>, fn: () => void): void;
|
|
122
|
+
/**
|
|
123
|
+
* Create a test case
|
|
124
|
+
*/
|
|
125
|
+
declare function it(name: string, fn: TestFunction): void;
|
|
126
|
+
declare function it(name: string, options: Partial<TestCase>, fn: TestFunction): void;
|
|
127
|
+
/**
|
|
128
|
+
* Alias for it()
|
|
129
|
+
*/
|
|
130
|
+
declare const test: typeof it;
|
|
131
|
+
/**
|
|
132
|
+
* Skip a test suite
|
|
133
|
+
*/
|
|
134
|
+
declare function describe_skip(name: string, fn: () => void): void;
|
|
135
|
+
/**
|
|
136
|
+
* Skip a test case
|
|
137
|
+
*/
|
|
138
|
+
declare function it_skip(name: string, fn: TestFunction): void;
|
|
139
|
+
/**
|
|
140
|
+
* Focus on a test suite (only run this suite)
|
|
141
|
+
*/
|
|
142
|
+
declare function describe_only(name: string, fn: () => void): void;
|
|
143
|
+
/**
|
|
144
|
+
* Focus on a test case (only run this test)
|
|
145
|
+
*/
|
|
146
|
+
declare function it_only(name: string, fn: TestFunction): void;
|
|
147
|
+
/**
|
|
148
|
+
* Setup function to run before all tests in a suite
|
|
149
|
+
*/
|
|
150
|
+
declare function beforeAll(fn: () => Promise<void> | void): void;
|
|
151
|
+
/**
|
|
152
|
+
* Teardown function to run after all tests in a suite
|
|
153
|
+
*/
|
|
154
|
+
declare function afterAll(fn: () => Promise<void> | void): void;
|
|
155
|
+
/**
|
|
156
|
+
* Setup function to run before each test in a suite
|
|
157
|
+
*/
|
|
158
|
+
declare function beforeEach(fn: () => Promise<void> | void): void;
|
|
159
|
+
/**
|
|
160
|
+
* Teardown function to run after each test in a suite
|
|
161
|
+
*/
|
|
162
|
+
declare function afterEach(fn: () => Promise<void> | void): void;
|
|
163
|
+
/**
|
|
164
|
+
* Run all registered test suites
|
|
165
|
+
*/
|
|
166
|
+
declare function runTests(config?: Partial<TestConfig>): Promise<TestResult[]>;
|
|
167
|
+
/**
|
|
168
|
+
* Clear all registered test suites
|
|
169
|
+
*/
|
|
170
|
+
declare function clearTests(): void;
|
|
171
|
+
/**
|
|
172
|
+
* Create a test fixture
|
|
173
|
+
*/
|
|
174
|
+
declare function fixture<T>(name: string, setup: () => T | Promise<T>, teardown?: (fixture: T) => void | Promise<void>): {
|
|
175
|
+
name: string;
|
|
176
|
+
create(): Promise<T>;
|
|
177
|
+
destroy(instance: T): Promise<void>;
|
|
178
|
+
};
|
|
179
|
+
/**
|
|
180
|
+
* Create a mock function
|
|
181
|
+
*/
|
|
182
|
+
declare function createMock<T extends (...args: any[]) => any>(implementation?: T): MockFunction;
|
|
183
|
+
/**
|
|
184
|
+
* Create a spy function
|
|
185
|
+
*/
|
|
186
|
+
declare function createSpy<T extends (...args: any[]) => any>(target: any, method: string): SpyFunction;
|
|
187
|
+
/**
|
|
188
|
+
* Wait for a condition to be true
|
|
189
|
+
*/
|
|
190
|
+
declare function waitFor(condition: () => boolean | Promise<boolean>, options?: {
|
|
191
|
+
timeout?: number;
|
|
192
|
+
interval?: number;
|
|
193
|
+
}): Promise<void>;
|
|
194
|
+
/**
|
|
195
|
+
* Create a page object for E2E testing
|
|
196
|
+
*/
|
|
197
|
+
declare function createPageObject(definition: PageObject): {
|
|
198
|
+
goto(page: any): Promise<void>;
|
|
199
|
+
element(name: string): string;
|
|
200
|
+
action(page: any, name: string, ...args: any[]): Promise<any>;
|
|
201
|
+
assert(page: any, name: string, ...args: any[]): Promise<void>;
|
|
202
|
+
name: string;
|
|
203
|
+
url?: string;
|
|
204
|
+
selectors: Record<string, string>;
|
|
205
|
+
actions: Record<string, (...args: any[]) => Promise<any>>;
|
|
206
|
+
assertions: Record<string, (...args: any[]) => Promise<void>>;
|
|
207
|
+
};
|
|
208
|
+
/**
|
|
209
|
+
* Integration with LokaScript core for behavior testing
|
|
210
|
+
*/
|
|
211
|
+
declare function createLokaScriptTestContext(hyperfixi: any): {
|
|
212
|
+
compileAndTest(script: string, element: Element, event?: string): Promise<any>;
|
|
213
|
+
testCompilation(script: string): Promise<{
|
|
214
|
+
success: boolean;
|
|
215
|
+
result: any;
|
|
216
|
+
error?: never;
|
|
217
|
+
} | {
|
|
218
|
+
success: boolean;
|
|
219
|
+
error: unknown;
|
|
220
|
+
result?: never;
|
|
221
|
+
}>;
|
|
222
|
+
testExecution(script: string, element: Element, eventType?: string): Promise<{
|
|
223
|
+
executed: boolean;
|
|
224
|
+
compiled: any;
|
|
225
|
+
}>;
|
|
226
|
+
};
|
|
227
|
+
/**
|
|
228
|
+
* Quick start function for basic testing setup
|
|
229
|
+
*/
|
|
230
|
+
declare function quickStartTesting(options?: {
|
|
231
|
+
environment?: TestEnvironment;
|
|
232
|
+
browser?: BrowserType;
|
|
233
|
+
headless?: boolean;
|
|
234
|
+
baseURL?: string;
|
|
235
|
+
testFiles?: string[];
|
|
236
|
+
}): Promise<{
|
|
237
|
+
config: Partial<TestConfig>;
|
|
238
|
+
run: () => Promise<TestResult[]>;
|
|
239
|
+
clear: typeof clearTests;
|
|
240
|
+
}>;
|
|
241
|
+
/**
|
|
242
|
+
* Version information
|
|
243
|
+
*/
|
|
244
|
+
declare const VERSION = "0.1.0";
|
|
245
|
+
|
|
246
|
+
export { BrowserType, CoreTestRunner, DEFAULT_CONFIG, MockFunction, PageObject, ParallelTestRunner, PerformanceMetrics, SpyFunction, TestCase, TestConfig, TestContext, TestEnvironment, TestFunction, TestResult, TestRunner, TestSuite, VERSION, afterAll, afterEach, beforeAll, beforeEach, clearTests, createLokaScriptTestContext, createMock, createPageObject, createSpy, createTestRunner, describe, describe_only, describe_skip, fixture, it, it_only, it_skip, measurePerformance, quickStartTesting, runTests, test, waitFor };
|