- Add HVAC_Test_User_Factory class with: * User creation with specific roles * Multiple role support * Persona management system * Account cleanup integration - Create comprehensive test suite in HVAC_Test_User_Factory_Test.php - Update testing improvement plan documentation - Add implementation decisions to project memory bank - Restructure .gitignore with: * Whitelist approach for better file management * Explicit backup exclusions * Specific bin directory inclusions Part of the Account Management component from the testing framework improvement plan.
30 lines
No EOL
1.1 KiB
TypeScript
30 lines
No EOL
1.1 KiB
TypeScript
import { Reporter, TestCase, TestResult, FullConfig, Suite, FullResult } from '@playwright/test/reporter';
|
|
import { HtmlReporter } from './HtmlReporter';
|
|
import { MarkdownReporter } from './MarkdownReporter';
|
|
|
|
class CustomReporterPlugin implements Reporter {
|
|
private htmlReporter: HtmlReporter;
|
|
private markdownReporter: MarkdownReporter;
|
|
|
|
constructor() {
|
|
this.htmlReporter = new HtmlReporter({ outputDir: 'test-results/custom-html-report' });
|
|
this.markdownReporter = new MarkdownReporter({ outputFile: 'test-results/test-report.md' });
|
|
}
|
|
|
|
async onBegin(config: FullConfig, suite: Suite) {
|
|
await this.htmlReporter.onBegin?.(config, suite);
|
|
await this.markdownReporter.onBegin?.(config, suite);
|
|
}
|
|
|
|
async onTestEnd(test: TestCase, result: TestResult) {
|
|
await this.htmlReporter.onTestEnd?.(test, result);
|
|
await this.markdownReporter.onTestEnd?.(test, result);
|
|
}
|
|
|
|
async onEnd(result: FullResult): Promise<void> {
|
|
await this.htmlReporter.onEnd?.();
|
|
await this.markdownReporter.onEnd?.();
|
|
}
|
|
}
|
|
|
|
export default CustomReporterPlugin; |