refactor
This commit is contained in:
@@ -4,9 +4,9 @@ import { configureDIContainer, resetDIContainer } from "../../../apps/companion/
|
||||
import { DI_TOKENS } from "../../../apps/companion/main/di-tokens";
|
||||
import { OverlaySyncService } from "@gridpilot/automation/application/services/OverlaySyncService";
|
||||
import { LoggerPort } from "@gridpilot/automation/application/ports/LoggerPort";
|
||||
import { IAutomationLifecycleEmitter, LifecycleCallback } from "@gridpilot/automation/infrastructure/adapters/IAutomationLifecycleEmitter";
|
||||
import { IAutomationLifecycleEmitter, LifecycleCallback } from "@gridpilot/automation/infrastructure//IAutomationLifecycleEmitter";
|
||||
import { AutomationEventPublisherPort, AutomationEvent } from "@gridpilot/automation/application/ports/AutomationEventPublisherPort";
|
||||
import { ConsoleLogAdapter } from "@gridpilot/automation/infrastructure/adapters/logging/ConsoleLogAdapter";
|
||||
import { ConsoleLogAdapter } from "@gridpilot/automation/infrastructure//logging/ConsoleLogAdapter";
|
||||
import { describe, it, expect, beforeEach, afterEach, vi, SpyInstance } from 'vitest';
|
||||
|
||||
describe("OverlaySyncService Integration with ConsoleLogAdapter", () => {
|
||||
|
||||
@@ -87,7 +87,7 @@ describe('Browser Mode Integration - GREEN Phase', () => {
|
||||
});
|
||||
|
||||
const { PlaywrightAutomationAdapter } = await import(
|
||||
'core/automation/infrastructure/adapters/automation'
|
||||
'core/automation/infrastructure//automation'
|
||||
);
|
||||
|
||||
adapter = new PlaywrightAutomationAdapter({
|
||||
@@ -111,7 +111,7 @@ describe('Browser Mode Integration - GREEN Phase', () => {
|
||||
});
|
||||
|
||||
const { PlaywrightAutomationAdapter } = await import(
|
||||
'core/automation/infrastructure/adapters/automation'
|
||||
'core/automation/infrastructure//automation'
|
||||
);
|
||||
|
||||
adapter = new PlaywrightAutomationAdapter({
|
||||
@@ -135,7 +135,7 @@ describe('Browser Mode Integration - GREEN Phase', () => {
|
||||
});
|
||||
|
||||
const { PlaywrightAutomationAdapter } = await import(
|
||||
'core/automation/infrastructure/adapters/automation'
|
||||
'core/automation/infrastructure//automation'
|
||||
);
|
||||
|
||||
adapter = new PlaywrightAutomationAdapter({
|
||||
@@ -164,7 +164,7 @@ describe('Browser Mode Integration - GREEN Phase', () => {
|
||||
});
|
||||
|
||||
const { PlaywrightAutomationAdapter } = await import(
|
||||
'core/automation/infrastructure/adapters/automation'
|
||||
'core/automation/infrastructure//automation'
|
||||
);
|
||||
|
||||
adapter = new PlaywrightAutomationAdapter({
|
||||
@@ -185,7 +185,7 @@ describe('Browser Mode Integration - GREEN Phase', () => {
|
||||
});
|
||||
|
||||
const { PlaywrightAutomationAdapter } = await import(
|
||||
'core/automation/infrastructure/adapters/automation'
|
||||
'core/automation/infrastructure//automation'
|
||||
);
|
||||
|
||||
adapter = new PlaywrightAutomationAdapter({
|
||||
@@ -228,7 +228,7 @@ describe('Browser Mode Integration - GREEN Phase', () => {
|
||||
};
|
||||
|
||||
const { PlaywrightAutomationAdapter } = await import(
|
||||
'core/automation/infrastructure/adapters/automation'
|
||||
'core/automation/infrastructure//automation'
|
||||
);
|
||||
|
||||
adapter = new PlaywrightAutomationAdapter(
|
||||
@@ -259,7 +259,7 @@ describe('Browser Mode Integration - GREEN Phase', () => {
|
||||
});
|
||||
|
||||
const { PlaywrightAutomationAdapter } = await import(
|
||||
'core/automation/infrastructure/adapters/automation'
|
||||
'core/automation/infrastructure//automation'
|
||||
);
|
||||
|
||||
const userDataDir = path.join(process.cwd(), 'test-browser-data');
|
||||
@@ -290,7 +290,7 @@ describe('Browser Mode Integration - GREEN Phase', () => {
|
||||
configurable: true
|
||||
});
|
||||
const { PlaywrightAutomationAdapter } = await import(
|
||||
'core/automation/infrastructure/adapters/automation'
|
||||
'core/automation/infrastructure//automation'
|
||||
);
|
||||
const { BrowserModeConfigLoader } = await import(
|
||||
'../../../core/automation/infrastructure/config/BrowserModeConfig'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { describe, it, expect, beforeEach, vi } from 'vitest';
|
||||
import { Result } from '../../../core/shared/result/Result';
|
||||
import { CheckoutPriceExtractor } from '../../../core/automation/infrastructure/adapters/automation/CheckoutPriceExtractor';
|
||||
import { CheckoutPriceExtractor } from '../../../core/automation/infrastructure//automation/CheckoutPriceExtractor';
|
||||
import { CheckoutStateEnum } from '@gridpilot/automation/domain/value-objects/CheckoutState';
|
||||
|
||||
/**
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*/
|
||||
|
||||
import { describe, it, expect, beforeAll, afterAll } from 'vitest';
|
||||
import { FixtureServer, getAllStepFixtureMappings, PlaywrightAutomationAdapter } from 'core/automation/infrastructure/adapters/automation';
|
||||
import { FixtureServer, getAllStepFixtureMappings, PlaywrightAutomationAdapter } from 'core/automation/infrastructure//automation';
|
||||
|
||||
declare const getComputedStyle: any;
|
||||
declare const document: any;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, it, expect, beforeEach, afterEach, vi } from 'vitest';
|
||||
import { MockBrowserAutomationAdapter } from 'core/automation/infrastructure/adapters/automation';
|
||||
import { MockBrowserAutomationAdapter } from 'core/automation/infrastructure//automation';
|
||||
import { StepId } from '@gridpilot/automation/domain/value-objects/StepId';
|
||||
|
||||
describe('MockBrowserAutomationAdapter Integration Tests', () => {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { describe, test, expect } from 'vitest'
|
||||
import type { Page } from 'playwright'
|
||||
import { PlaywrightAutomationAdapter } from 'core/automation/infrastructure/adapters/automation'
|
||||
import { PlaywrightAutomationAdapter } from 'core/automation/infrastructure//automation'
|
||||
|
||||
describe('CarsFlow integration', () => {
|
||||
test('adapter emits panel-attached then action-started then action-complete for performAddCar', async () => {
|
||||
|
||||
@@ -4,7 +4,7 @@ import type { AutomationEvent } from 'core/automation/application/ports/IAutomat
|
||||
import type {
|
||||
IAutomationLifecycleEmitter,
|
||||
LifecycleCallback,
|
||||
} from 'core/automation/infrastructure/adapters/IAutomationLifecycleEmitter';
|
||||
} from 'core/automation/infrastructure//IAutomationLifecycleEmitter';
|
||||
import type {
|
||||
OverlayAction,
|
||||
ActionAck,
|
||||
|
||||
@@ -2,7 +2,7 @@ import { describe, it, expect, beforeEach, afterEach } from 'vitest';
|
||||
import { DIContainer } from '../../../..//apps/companion/main/di-container';
|
||||
import type { HostedSessionConfig } from '@gridpilot/automation/domain/types/HostedSessionConfig';
|
||||
import { StepId } from '@gridpilot/automation/domain/value-objects/StepId';
|
||||
import { PlaywrightAutomationAdapter } from '../../../..//core/automation/infrastructure/adapters/automation';
|
||||
import { PlaywrightAutomationAdapter } from '../../../..//core/automation/infrastructure//automation';
|
||||
|
||||
describe('companion start automation - browser mode refresh wiring', () => {
|
||||
const originalEnv = { ...process.env };
|
||||
|
||||
@@ -2,7 +2,7 @@ import { describe, it, expect, beforeEach, afterEach } from 'vitest';
|
||||
import { DIContainer } from '../../../..//apps/companion/main/di-container';
|
||||
import type { HostedSessionConfig } from '@gridpilot/automation/domain/types/HostedSessionConfig';
|
||||
import { StepId } from '@gridpilot/automation/domain/value-objects/StepId';
|
||||
import { PlaywrightAutomationAdapter } from '../../../..//core/automation/infrastructure/adapters/automation';
|
||||
import { PlaywrightAutomationAdapter } from '../../../..//core/automation/infrastructure//automation';
|
||||
|
||||
describe('companion start automation - browser not connected at step 1', () => {
|
||||
const originalEnv = { ...process.env };
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { describe, it, expect, beforeEach, afterEach, vi } from 'vitest';
|
||||
import { DIContainer } from '../../../..//apps/companion/main/di-container';
|
||||
import type { HostedSessionConfig } from '@gridpilot/automation/domain/types/HostedSessionConfig';
|
||||
import { PlaywrightAutomationAdapter } from '../../../..//core/automation/infrastructure/adapters/automation';
|
||||
import { PlaywrightAutomationAdapter } from '../../../..//core/automation/infrastructure//automation';
|
||||
|
||||
describe('companion start automation - browser connection failure before steps', () => {
|
||||
const originalEnv = { ...process.env };
|
||||
|
||||
Reference in New Issue
Block a user