]> Piment Noir Git Repositories - e-mobility-charging-stations-simulator.git/commitdiff
refactor(tests): replace re-export hub with direct imports
authorJérôme Benoit <jerome.benoit@sap.com>
Fri, 10 Apr 2026 16:27:37 +0000 (18:27 +0200)
committerJérôme Benoit <jerome.benoit@sap.com>
Fri, 10 Apr 2026 16:27:37 +0000 (18:27 +0200)
Remove ChargingStationTestUtils.ts re-export hub and update all 73
test files to import directly from their defining modules
(StationHelpers, TestLifecycleHelpers, MockCaches, MockWebSocket).

Fix __testable__ barrel bypass in OCPP20RequestService-CallChain test.

Harmonize Web UI test imports to use composables/types barrels
consistently and export validateUUID from composables barrel.

Add 'Direct Imports' convention to TEST_STYLE_GUIDE.md §6.

81 files changed:
.serena/memories/code_style_conventions.md
tests/TEST_STYLE_GUIDE.md
tests/charging-station/AutomaticTransactionGenerator.test.ts
tests/charging-station/ChargingStation-Configuration.test.ts
tests/charging-station/ChargingStation-Connectors.test.ts
tests/charging-station/ChargingStation-Lifecycle.test.ts
tests/charging-station/ChargingStation-Resilience.test.ts
tests/charging-station/ChargingStation-Transactions.test.ts
tests/charging-station/ChargingStation.test.ts
tests/charging-station/ChargingStationTestUtils.ts [deleted file]
tests/charging-station/ConfigurationKeyUtils.test.ts
tests/charging-station/Helpers.test.ts
tests/charging-station/IdTagsCache.test.ts
tests/charging-station/broadcast-channel/ChargingStationWorkerBroadcastChannel.test.ts
tests/charging-station/ocpp/1.6/OCPP16IncomingRequestService-TriggerMessage.test.ts
tests/charging-station/ocpp/1.6/OCPP16Integration-Transactions.test.ts
tests/charging-station/ocpp/1.6/OCPP16RequestService-CallChain.test.ts
tests/charging-station/ocpp/1.6/OCPP16ResponseService-SimpleHandlers.test.ts
tests/charging-station/ocpp/1.6/OCPP16ServiceUtils-MeterValues.test.ts
tests/charging-station/ocpp/1.6/OCPP16ServiceUtils-SignedMeterValues.test.ts
tests/charging-station/ocpp/1.6/OCPP16ServiceUtils.test.ts
tests/charging-station/ocpp/1.6/OCPP16TestUtils.ts
tests/charging-station/ocpp/2.0/OCPP20CertSigningRetryManager.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-CertificateSigned.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-ClearCache.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-CustomerInformation.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-DataTransfer.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-DeleteCertificate.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-GetBaseReport.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-GetInstalledCertificateIds.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-GetLog.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-GetTransactionStatus.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-GetVariables.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-InstallCertificate.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-LocalAuthList.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-MasterPass.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-RemoteStartAuth.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-RequestStartTransaction.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-RequestStopTransaction.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-Reset.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-SetNetworkProfile.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-SetVariables.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-TriggerMessage.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-UnlockConnector.test.ts
tests/charging-station/ocpp/2.0/OCPP20IncomingRequestService-UpdateFirmware.test.ts
tests/charging-station/ocpp/2.0/OCPP20Integration-Certificate.test.ts
tests/charging-station/ocpp/2.0/OCPP20Integration.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestBuilders-SignedMeterValues.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-CallChain.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-DataTransfer.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-FirmwareStatusNotification.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-HeartBeat.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-ISO15118.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-LogStatusNotification.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-MeterValues.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-NotifyReport.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-SecurityEventNotification.test.ts
tests/charging-station/ocpp/2.0/OCPP20RequestService-SignCertificate.test.ts
tests/charging-station/ocpp/2.0/OCPP20ResponseService-BootNotification.test.ts
tests/charging-station/ocpp/2.0/OCPP20ResponseService-CacheUpdate.test.ts
tests/charging-station/ocpp/2.0/OCPP20ResponseService-SimpleHandlers.test.ts
tests/charging-station/ocpp/2.0/OCPP20ResponseService-TransactionEvent.test.ts
tests/charging-station/ocpp/2.0/OCPP20ServiceUtils-AuthCache.test.ts
tests/charging-station/ocpp/2.0/OCPP20ServiceUtils-ReconnectDelay.test.ts
tests/charging-station/ocpp/2.0/OCPP20ServiceUtils-StatusNotification.test.ts
tests/charging-station/ocpp/2.0/OCPP20ServiceUtils-TransactionEvent.test.ts
tests/charging-station/ocpp/2.0/OCPP20TestUtils.ts
tests/charging-station/ocpp/2.0/OCPP20VariableManager.test.ts
tests/charging-station/ocpp/OCPPServiceOperations.test.ts
tests/charging-station/ocpp/OCPPServiceUtils-meterValues.test.ts
tests/charging-station/ocpp/auth/OCPPAuthIntegration.test.ts
tests/charging-station/ocpp/auth/factories/AuthComponentFactory.test.ts
tests/helpers/TestLifecycleHelpers.ts
tests/utils/ChargingStationConfigurationUtils.test.ts
tests/utils/ErrorUtils.test.ts
tests/utils/MessageChannelUtils.test.ts
ui/web/src/composables/index.ts
ui/web/tests/unit/CSConnector.test.ts
ui/web/tests/unit/CSData.test.ts
ui/web/tests/unit/UIClient.test.ts
ui/web/tests/unit/Utils.test.ts

index e4d9ba492f5e57b9b09181aef03e568beee7479f..313263c60532575f2761cab4c846465ac8bf94a7 100644 (file)
@@ -98,7 +98,7 @@ Full guide: `tests/TEST_STYLE_GUIDE.md`. Key points:
 - **Station factory**: `createMockChargingStation(options?)` returns `{ station, mocks }` with MockWebSocket, parentPortMessages, file system mocks
 - **Auth factories**: `createMockAuthRequest()`, `createMockAuthorizationResult()`, `createMockAuthService()` in `tests/charging-station/ocpp/auth/helpers/MockFactories.ts`
 - **Transaction setup**: `setupConnectorWithTransaction(station, connectorId, { transactionId, idTag? })`
-- **Re-export hub**: `tests/charging-station/ChargingStationTestUtils.ts` aggregates all test utilities
+- **Direct imports**: Test files import from the defining module, not through re-export hubs. `src/` barrels remain (public API)
 - **`__testable__` pattern**: `ocpp/1.6/__testable__/` and `ocpp/2.0/__testable__/` directories expose internal classes (e.g., `OCPP20VariableManagerTestable`, `OCPP20RequestServiceTestable`) for unit testing private internals. Import from `__testable__/index.ts` barrel in tests only
 
 ## Python Conventions (tests/ocpp-server/)
index 66818a0c6c962f905eb3d2abe09987ebcbb66842..50cb7c261fdfc3cb0e51bab8b95c8b40d2fc908e 100644 (file)
@@ -228,6 +228,22 @@ const TEST_STATION_NAME = 'CS-TEST-001'
 
 Available constants: `tests/charging-station/ChargingStationTestConstants.ts`
 
+### Direct Imports (No Re-Export Hubs)
+
+Import from the file that **defines** the symbol — never through an intermediate re-export file.
+
+```typescript
+// ✅ Good - Direct to defining module
+import { createMockChargingStation } from './helpers/StationHelpers.js'
+import { standardCleanup } from '../helpers/TestLifecycleHelpers.js'
+import { MockWebSocket } from './mocks/MockWebSocket.js'
+
+// ❌ Bad - Through re-export hub
+import { createMockChargingStation, standardCleanup } from './ChargingStationTestUtils.js'
+```
+
+**Exception**: `src/` barrel imports (e.g., `src/types/index.js`) are the public API of production modules — use them as-is.
+
 ---
 
 ## 7. Assertions
index 3928f1c9fb620de63bdbf3cdaf223fbfcaf34d4d..ba5bbae2302f1ce73a4270284ce21b1badf5a0d5 100644 (file)
@@ -23,8 +23,8 @@ import { AutomaticTransactionGenerator } from '../../src/charging-station/Automa
 import { BaseError } from '../../src/exception/index.js'
 import { type StartTransactionResult } from '../../src/types/index.js'
 import { Constants } from '../../src/utils/Constants.js'
-import { flushMicrotasks } from '../helpers/TestLifecycleHelpers.js'
-import { createMockChargingStation, standardCleanup } from './ChargingStationTestUtils.js'
+import { flushMicrotasks, standardCleanup } from '../helpers/TestLifecycleHelpers.js'
+import { createMockChargingStation } from './helpers/StationHelpers.js'
 
 type ConnectorStatus = ReturnType<AutomaticTransactionGenerator['connectorsStatus']['get']>
 
index e233c4adca9dee625b49298ccdaee1e93a5856e2..ad7b0c2e1fece92b80eded1d7943a36e49c82d1f 100644 (file)
@@ -10,7 +10,7 @@ import type { ChargingStation } from '../../src/charging-station/index.js'
 import { AvailabilityType, RegistrationStatusEnumType } from '../../src/types/index.js'
 import { standardCleanup, withMockTimers } from '../helpers/TestLifecycleHelpers.js'
 import { TEST_HEARTBEAT_INTERVAL_MS, TEST_ONE_HOUR_MS } from './ChargingStationTestConstants.js'
-import { cleanupChargingStation, createMockChargingStation } from './ChargingStationTestUtils.js'
+import { cleanupChargingStation, createMockChargingStation } from './helpers/StationHelpers.js'
 
 await describe('ChargingStation Configuration Management', async () => {
   // ===== B02/B03 BOOT NOTIFICATION BEHAVIOR TESTS =====
index 98e65e56c31f7880949639b57dd91b8b0d9c3367..894c5f1364d2c146a16739c177e448e382428f2e 100644 (file)
@@ -11,7 +11,7 @@ import { resetConnectorStatus } from '../../src/charging-station/Helpers.js'
 import { RegistrationStatusEnumType } from '../../src/types/index.js'
 import { standardCleanup } from '../helpers/TestLifecycleHelpers.js'
 import { TEST_ONE_HOUR_MS } from './ChargingStationTestConstants.js'
-import { cleanupChargingStation, createMockChargingStation } from './ChargingStationTestUtils.js'
+import { cleanupChargingStation, createMockChargingStation } from './helpers/StationHelpers.js'
 
 await describe('ChargingStation Connector and EVSE State', async () => {
   await describe('Connector Query', async () => {
index 076f68ff2951ab9ebb7bb290d29b9ead0f758ea6..4a299f9742f2fdcc352a457241addf98db97d01d 100644 (file)
@@ -8,7 +8,7 @@ import { afterEach, beforeEach, describe, it } from 'node:test'
 import type { ChargingStation } from '../../src/charging-station/index.js'
 
 import { standardCleanup } from '../helpers/TestLifecycleHelpers.js'
-import { cleanupChargingStation, createMockChargingStation } from './ChargingStationTestUtils.js'
+import { cleanupChargingStation, createMockChargingStation } from './helpers/StationHelpers.js'
 
 await describe('ChargingStation Lifecycle', async () => {
   await describe('Start/Stop Operations', async () => {
index a5929b791d51c8cf47172eb98aa1d5a5e208a238..e31462ed57808bea359765001e543db51dabf6ba 100644 (file)
@@ -10,7 +10,7 @@ import type { ChargingStation } from '../../src/charging-station/index.js'
 import { RegistrationStatusEnumType, RequestCommand } from '../../src/types/index.js'
 import { standardCleanup } from '../helpers/TestLifecycleHelpers.js'
 import { TEST_HEARTBEAT_INTERVAL_MS } from './ChargingStationTestConstants.js'
-import { cleanupChargingStation, createMockChargingStation } from './ChargingStationTestUtils.js'
+import { cleanupChargingStation, createMockChargingStation } from './helpers/StationHelpers.js'
 
 await describe('ChargingStation Resilience', async () => {
   await describe('Error Recovery and Resilience', async () => {
index d6d5c7980f36a35ab09e34ee4671c81445219029..4e6cb488baff1122ed580fe9082307ac8c7faefe 100644 (file)
@@ -16,7 +16,7 @@ import {
   withMockTimers,
 } from '../helpers/TestLifecycleHelpers.js'
 import { TEST_HEARTBEAT_INTERVAL_MS, TEST_ID_TAG } from './ChargingStationTestConstants.js'
-import { cleanupChargingStation, createMockChargingStation } from './ChargingStationTestUtils.js'
+import { cleanupChargingStation, createMockChargingStation } from './helpers/StationHelpers.js'
 
 await describe('ChargingStation Transaction Management', async () => {
   await describe('Transaction Query', async () => {
index 023ab14e54b2755907956475c8fc78de9a36a8d8..7ea2edb2357feeffbc87fdd832823ebe176b9539 100644 (file)
@@ -21,14 +21,9 @@ import {
   TEST_TRANSACTION_ENERGY_WH,
   TEST_TRANSACTION_ID,
 } from './ChargingStationTestConstants.js'
-import {
-  cleanupChargingStation,
-  createMockChargingStation,
-  MockIdTagsCache,
-  MockSharedLRUCache,
-  MockWebSocket,
-  WebSocketReadyState,
-} from './ChargingStationTestUtils.js'
+import { cleanupChargingStation, createMockChargingStation } from './helpers/StationHelpers.js'
+import { MockIdTagsCache, MockSharedLRUCache } from './mocks/MockCaches.js'
+import { MockWebSocket, WebSocketReadyState } from './mocks/MockWebSocket.js'
 
 await describe('ChargingStation', async () => {
   await describe('Test Utilities', async () => {
diff --git a/tests/charging-station/ChargingStationTestUtils.ts b/tests/charging-station/ChargingStationTestUtils.ts
deleted file mode 100644 (file)
index 72fe49c..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-/**
- * Utilities for creating MOCK ChargingStation instances in tests
- *
- * This file provides factory functions to instantiate mock ChargingStation
- * objects (lightweight stubs) with properly isolated dependencies for testing.
- *
- * Key patterns:
- * - MockWebSocket: Captures sent messages for assertion
- * - Singleton mocking: Overrides getInstance() for shared caches
- * - Cleanup utilities: Prevents test pollution via timer/listener cleanup
- * @see tests/charging-station/helpers/StationHelpers.ts for mock factory implementation
- * @see tests/charging-station/ChargingStationTestConstants.ts for test constants
- */
-
-// Re-export test lifecycle helpers
-export {
-  clearConnectorTransaction,
-  setupConnectorWithTransaction,
-  standardCleanup,
-} from '../helpers/TestLifecycleHelpers.js'
-
-// Re-export all helper functions and types from StationHelpers
-export {
-  type ChargingStationMocks,
-  cleanupChargingStation,
-  createConnectorStatus,
-  type CreateConnectorStatusOptions,
-  createMockChargingStation,
-  createMockChargingStationTemplate,
-  type MockChargingStation,
-  type MockChargingStationOptions,
-  type MockChargingStationResult,
-  type MockOCPPIncomingRequestService,
-  type MockOCPPRequestService,
-  resetChargingStationState,
-} from './helpers/StationHelpers.js'
-
-export { MockIdTagsCache, MockSharedLRUCache } from './mocks/MockCaches.js'
-// Re-export all mock classes
-export { MockWebSocket, WebSocketReadyState } from './mocks/MockWebSocket.js'
index 7e1d8fae40af1f774e05d9b46056b4432c2f6c18..f395ff5a8103fdc8bca1212fdf4ccb9c5a84d5b4 100644 (file)
@@ -17,7 +17,7 @@ import {
 import { OCPP20ComponentName, OCPPVersion, StandardParametersKey } from '../../src/types/index.js'
 import { logger } from '../../src/utils/index.js'
 import { standardCleanup } from '../helpers/TestLifecycleHelpers.js'
-import { createMockChargingStation } from './ChargingStationTestUtils.js'
+import { createMockChargingStation } from './helpers/StationHelpers.js'
 
 const TEST_KEY_1 = 'TestKey1'
 const MIXED_CASE_KEY = 'MiXeDkEy'
index d407f5410cbcdd97e0ea1ff74768cc9816f37caf..8b45004d6f0e16e9c6443e0b1c3f377128fecc43 100644 (file)
@@ -42,7 +42,7 @@ import { TEST_CHARGING_STATION_BASE_NAME } from './ChargingStationTestConstants.
 import {
   createMockChargingStation,
   createMockChargingStationTemplate,
-} from './ChargingStationTestUtils.js'
+} from './helpers/StationHelpers.js'
 
 await describe('Helpers', async () => {
   let chargingStationTemplate: ChargingStationTemplate
index 5e5bf08167af3fefc85e74c1d80db54c4938eea1..82b92db3bc7f1e1c3ee33c7d451e9f547c3df1e3 100644 (file)
@@ -21,7 +21,7 @@ import { getIdTagsFile } from '../../src/charging-station/Helpers.js'
 import { IdTagsCache } from '../../src/charging-station/IdTagsCache.js'
 import { IdTagDistribution } from '../../src/types/index.js'
 import { standardCleanup } from '../helpers/TestLifecycleHelpers.js'
-import { createMockChargingStation } from './ChargingStationTestUtils.js'
+import { createMockChargingStation } from './helpers/StationHelpers.js'
 
 const TEST_ID_TAGS = ['TAG-001', 'TAG-002', 'TAG-003']
 const TEST_ID_TAGS_FILE = 'test-idtags.json'
index 71da1cb889562e51b04bbc68dcd4f456f6f21b3d..a11413e5d1f2bfbca76b5ea61d88d2a6cc298d6b 100644 (file)
@@ -27,7 +27,7 @@ import {
 import { Constants } from '../../../src/utils/index.js'
 import { flushMicrotasks, standardCleanup } from '../../helpers/TestLifecycleHelpers.js'
 import { TEST_TRANSACTION_ID_STRING } from '../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../helpers/StationHelpers.js'
 import { createMockStationWithRequestTracking } from '../ocpp/2.0/OCPP20TestUtils.js'
 
 // ============================================================================
index 861c8fab971911165d00a1541e0591372fde7a49..a4f2040953b4d169eefcb47ba080f8fde245544e 100644 (file)
@@ -24,7 +24,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { flushMicrotasks, standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   createOCPP16IncomingRequestTestContext,
   createOCPP16ListenerStation,
index aace2bbbc668a92befec7230472ebb6c050c3856..ca4782451e068d98a59b49729966e75712319409 100644 (file)
@@ -40,7 +40,7 @@ import {
   standardCleanup,
 } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME, TEST_ID_TAG } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 /**
  * Creates a shared station configured for cross-service integration tests,
index 9d724e1fbc4e3a8cad10d60d6306b56284bdbbf7..ad2db1fb83b6cd95fec94e5fe1fd3541bf50da41 100644 (file)
@@ -23,7 +23,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('OCPP 1.6 Request Call Chain — requestHandler → buildRequestPayload → sendMessage', async () => {
   let requestService: OCPP16RequestService
index fa540be7439750ea79a5348dda4f50cfaad4b5d9..a78b78952186c8270377753a9abd8828410a5f76 100644 (file)
@@ -9,7 +9,7 @@
 import assert from 'node:assert/strict'
 import { afterEach, beforeEach, describe, it } from 'node:test'
 
-import type { MockChargingStation } from '../../ChargingStationTestUtils.js'
+import type { MockChargingStation } from '../../helpers/StationHelpers.js'
 
 import { OCPP16ResponseService } from '../../../../src/charging-station/ocpp/1.6/OCPP16ResponseService.js'
 import {
@@ -26,7 +26,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { dispatchResponse } from './OCPP16TestUtils.js'
 
 /**
index bfc4c8a4849c23edcd1ea8a322696790acfb9f9c..0e61e1c3e8a5550a6add92617d2a6af4aa0b9990 100644 (file)
@@ -17,7 +17,7 @@ import {
   OCPPVersion,
 } from '../../../../src/types/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { createMeterValuesTemplate } from './OCPP16TestUtils.js'
 
 await describe('OCPP16ServiceUtils — MeterValues', async () => {
index 91f33e59bb32a3e754991e596363cdcb54d178ef..22beb41c0382e2a62624f47456a01e7be3128a8f 100644 (file)
@@ -27,7 +27,7 @@ import {
 } from '../../../../src/types/index.js'
 import { standardCleanup, withMockTimers } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_PUBLIC_KEY_HEX } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { createMeterValuesTemplate, upsertConfigurationKey } from './OCPP16TestUtils.js'
 
 await describe('OCPP 1.6 — Signed MeterValues', async () => {
index cc3d4f24615200aa875b1c59c223fa107ab1a5ec..5178e5d16c97d75bd09f8db5f4bbaf3a5f971987 100644 (file)
@@ -39,7 +39,7 @@ import {
 } from '../../../../src/types/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME, TEST_ID_TAG } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { getTestAuthCache } from '../auth/helpers/MockFactories.js'
 import { createCommandsSupport } from './OCPP16TestUtils.js'
 
index 490be5c45ffb1702fdff3a61b6e0cb54591a98ae..c77b1ee6fa46eeabefa6d7031be13bfecf53ee1a 100644 (file)
@@ -43,7 +43,7 @@ import {
   createMockChargingStation,
   type MockChargingStation,
   type MockOCPPRequestService,
-} from '../../ChargingStationTestUtils.js'
+} from '../../helpers/StationHelpers.js'
 
 // ============================================================================
 // Test Context Types
index fe12d5a11e2d794b0358a00da53ae846faada819..9884d90a9cc1967c140f7096e7f65ce51567b71a 100644 (file)
@@ -25,7 +25,7 @@ import {
   withMockTimers,
 } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { upsertConfigurationKey } from './OCPP20TestUtils.js'
 
 await describe('OCPP20CertSigningRetryManager', async () => {
index f22f3e2b861b419378ecc455193b50687b16a7a4..ee58d328b545d03e4985be3ef1075c52887c3494 100644 (file)
@@ -26,7 +26,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   INVALID_PEM_CERTIFICATE_MISSING_MARKERS,
   VALID_CERTIFICATE_CHAIN,
index 336936199758ad72d8d1d80fbb59ead8d259eddf..2c77a527a356914400a8582e43a3a800d2fb2b2a 100644 (file)
@@ -15,7 +15,7 @@ import { GenericStatus, OCPPVersion } from '../../../../src/types/index.js'
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('C11 - Clear Authorization Data in Authorization Cache', async () => {
   afterEach(() => {
index ea8d0eb9647dbca51e21b5a4f935b504f08df256..be8c6d08b7c410ac312084effb8b73702eb628b0 100644 (file)
@@ -22,7 +22,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { flushMicrotasks, standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('N32 - CustomerInformation', async () => {
   let station: ChargingStation
index bd6d895d71636498fb25547b5f38d5e93adc084b..2edb0e1bbb7e4c1a871336736a6b2a6d90555664 100644 (file)
@@ -14,7 +14,7 @@ import { DataTransferStatusEnumType, OCPPVersion } from '../../../../src/types/i
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('P01 - DataTransfer', async () => {
   let station: ChargingStation
index 131818a87655453af109e03616c7496834371dc7..bf67604ca99b289f89c063025bdafe4bc35121a7 100644 (file)
@@ -22,7 +22,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   createMockCertificateManager,
   createStationWithCertificateManager,
index 954bf0e2c964b03bb7ec4951fd0183ec0dad3446..e327a6bced223d7dc859065f64f3eff51677937b 100644 (file)
@@ -42,7 +42,7 @@ import {
   TEST_CHARGING_STATION_BASE_NAME,
   TEST_FIRMWARE_VERSION,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('B07 - Get Base Report', async () => {
   let station: ChargingStation
index f9f32bfcc63f90957db206fa78f2cfbd566e45a2..dc2c9e4536974a182da82089483c2ee9f6aa1024 100644 (file)
@@ -22,7 +22,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   createMockCertificateHashDataChain,
   createMockCertificateManager,
index 0a896fbe0a8b718ec634f3715ce1a50cdb10eabb..b5f709e414fa89667b7fa802f04505fa3568fd78 100644 (file)
@@ -27,7 +27,7 @@ import {
   withMockTimers,
 } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { createMockStationWithRequestTracking } from './OCPP20TestUtils.js'
 
 await describe('K01 - GetLog', async () => {
index 9e0ea95d5f0249689a7ec7f5166193c81d184dab..a43f7062a727f7c8c8f4ae114cb4b2b9c13f9491 100644 (file)
@@ -17,7 +17,7 @@ import {
   standardCleanup,
 } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('D14 - GetTransactionStatus', async () => {
   let station: ChargingStation
index 52cdfdfe24e738ba24f9683e9090dbf20aa55e85..4e0e8c702d8045962b9dc6e02caeadf5a4d1fa48 100644 (file)
@@ -27,7 +27,7 @@ import {
   TEST_CHARGING_STATION_BASE_NAME,
   TEST_CONNECTOR_ID_VALID_INSTANCE,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   resetLimits,
   resetReportingValueSize,
index 4793d4e8a0a1ba0ad77300559de8f54528e0e363..c4f38d15572beb34c7ab7c17b951a90a8a0f5ff6 100644 (file)
@@ -21,7 +21,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   EXPIRED_PEM_CERTIFICATE,
   INVALID_PEM_CERTIFICATE_MISSING_MARKERS,
index a3b381842b086353fc194f8a0fc3fdf9b1047492..4c10d69eabef36f0dcfb86d2d9db6763c88d60c1 100644 (file)
@@ -28,7 +28,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { upsertConfigurationKey } from './OCPP20TestUtils.js'
 
 await describe('OCPP20IncomingRequestService — LocalAuthList', async () => {
index c9ee625c46f5f540a64d90b0b3d3d84e5ef17d2a..710ac064b77d4e8d4d84883251373d5f7f4f5201 100644 (file)
@@ -25,7 +25,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { createMockAuthService } from '../auth/helpers/MockFactories.js'
 import {
   resetConnectorTransactionState,
index 02a6c7b48de59f42641794b384c6f8eb522731e2..6e3b8543bc749144c2ee742edac558fae80f32db 100644 (file)
@@ -22,10 +22,7 @@ import {
   RequestStartStopStatusEnumType,
 } from '../../../../src/types/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
-import {
-  cleanupChargingStation,
-  createMockChargingStation,
-} from '../../ChargingStationTestUtils.js'
+import { cleanupChargingStation, createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('G03 - Remote Start Pre-Authorization', async () => {
   let service: OCPP20IncomingRequestService | undefined
index 7a632ca909bb10ddf164d1c1983a26fc19914a07..f0ad2fbf577d673e65f27199f7ab8b6f36f889c5 100644 (file)
@@ -43,7 +43,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { flushMicrotasks, standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   createMockAuthorizationResult,
   createMockAuthService,
index 45ec00276de25bfa44863917278ce9a15e02ae98..ab0e90860b42ca9da8c210c30987270d17c54574 100644 (file)
@@ -33,7 +33,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { flushMicrotasks, standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { createMockAuthService } from '../auth/helpers/MockFactories.js'
 import {
   createOCPP20ListenerStation,
index 20d918fbd27297abe9daacb2606e0be59bcb0013..4cefedd0947da5a502e2fa83169a74f187d6c917 100644 (file)
@@ -11,7 +11,7 @@ import type {
   OCPP20ResetResponse,
   Reservation,
 } from '../../../../src/types/index.js'
-import type { MockChargingStation } from '../../ChargingStationTestUtils.js'
+import type { MockChargingStation } from '../../helpers/StationHelpers.js'
 
 import { createTestableIncomingRequestService } from '../../../../src/charging-station/ocpp/2.0/__testable__/index.js'
 import { OCPP20IncomingRequestService } from '../../../../src/charging-station/ocpp/2.0/OCPP20IncomingRequestService.js'
index 525bc75b6ea95ecab342ed66cf81c81bf6e89537..448ecee986a39e4c2259b7466549c5762c0b227c 100644 (file)
@@ -22,7 +22,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('B43 - SetNetworkProfile', async () => {
   let station: ChargingStation
index 487bf2f9512b011e0589d224b1683943c2b271e1..be1da66c2976c3e6ede57c46724e955686f0556f 100644 (file)
@@ -31,7 +31,7 @@ import {
   TEST_CHARGING_STATION_BASE_NAME,
   TEST_CONNECTOR_ID_VALID_INSTANCE,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   resetLimits,
   resetValueSizeLimits,
index 7867bd8ce056b6f1f26132f6cd25828fd92d9683..281e0d58333e35e0ffd43e5e5647ac2f4d99f56e 100644 (file)
@@ -12,7 +12,7 @@ import type {
   OCPP20TriggerMessageResponse,
   RequestParams,
 } from '../../../../src/types/index.js'
-import type { MockChargingStation } from '../../ChargingStationTestUtils.js'
+import type { MockChargingStation } from '../../helpers/StationHelpers.js'
 
 import { createTestableIncomingRequestService } from '../../../../src/charging-station/ocpp/2.0/__testable__/index.js'
 import { OCPP20IncomingRequestService } from '../../../../src/charging-station/ocpp/2.0/OCPP20IncomingRequestService.js'
@@ -28,7 +28,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { flushMicrotasks, standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 /**
  * Create a mock station suitable for TriggerMessage tests.
index 09d144645cc7b29b7b6f17634432da79a8f603ff..b9f9af980eb89c9db4157dbd49827631293c1361 100644 (file)
@@ -10,7 +10,7 @@ import type {
   OCPP20UnlockConnectorRequest,
   OCPP20UnlockConnectorResponse,
 } from '../../../../src/types/index.js'
-import type { MockChargingStation } from '../../ChargingStationTestUtils.js'
+import type { MockChargingStation } from '../../helpers/StationHelpers.js'
 
 import { createTestableIncomingRequestService } from '../../../../src/charging-station/ocpp/2.0/__testable__/index.js'
 import { OCPP20IncomingRequestService } from '../../../../src/charging-station/ocpp/2.0/OCPP20IncomingRequestService.js'
@@ -23,7 +23,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 /**
  * Create a mock station suitable for UnlockConnector tests.
index 4b120bb5eb3f4aec79060c5c9006fd6fda384783..6a294c00e72c8b2692a3894cf8091774c551a1eb 100644 (file)
@@ -28,7 +28,7 @@ import {
   withMockTimers,
 } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   createMockCertificateManager,
   createMockStationWithRequestTracking,
index d4301e7499173de0f7001a17f61dfa540aedf490..87ccc9ed1b6c867ccd780de765a516ef849839f3 100644 (file)
@@ -26,7 +26,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 /** @returns A mock station configured for certificate integration tests */
 function createIntegrationStation (): ChargingStation {
index c60c63a2f27245f845a0b2a12557ef02122627d7..06423a276fb696a2c00f94f228196be52cc6902d 100644 (file)
@@ -28,7 +28,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { resetLimits } from './OCPP20TestUtils.js'
 
 /** @returns A mock station configured for integration tests */
index be06caa6ef94218363661ae2c7490216fa0138b4..79c078ac2031ab3da547e87e00c54c3a17a3543b 100644 (file)
@@ -30,7 +30,7 @@ import {
   TEST_PUBLIC_KEY_HEX,
   TEST_TRANSACTION_ID_STRING,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 const energyTemplate: SampledValueTemplate = {
   measurand: MeterValueMeasurand.ENERGY_ACTIVE_IMPORT_REGISTER,
index 1d61794fc8b2ae59e06bef05a71903a51db9664b..38b9848ef6efcbe4f14aefaaa4305d4729cb22aa 100644 (file)
@@ -13,7 +13,7 @@ import {
   createTestableRequestService,
   type SendMessageMock,
   type TestableOCPP20RequestService,
-} from '../../../../src/charging-station/ocpp/2.0/__testable__/OCPP20RequestServiceTestable.js'
+} from '../../../../src/charging-station/ocpp/2.0/__testable__/index.js'
 import {
   ConnectorStatusEnum,
   OCPP20ConnectorStatusEnumType,
@@ -27,7 +27,7 @@ import {
 import { Constants, generateUUID } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('OCPP 2.0 Request Call Chain — requestHandler → buildRequestPayload → sendMessage', async () => {
   let service: TestableOCPP20RequestService
index 7f0b2481bea7b0126afd7580e6a368b610c376c3..4314c065c567511d1fcad278806b706e1cbda59a 100644 (file)
@@ -22,7 +22,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('P02 - DataTransfer', async () => {
   let station: ChargingStation
index dada4577199c7ca3e74387ed217835c03ab3d44f..c685c38265068692eab150c83a937102be3fcd39 100644 (file)
@@ -23,7 +23,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('J01 - FirmwareStatusNotification', async () => {
   let station: ChargingStation
index fa326ddf880eee012692d378e7c552af0e558d89..d2e1fc74b39e355385644d1b2a4dd3f64b0dea88 100644 (file)
@@ -21,7 +21,7 @@ import {
   TEST_CHARGING_STATION_BASE_NAME,
   TEST_FIRMWARE_VERSION,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   createOCPP20RequestTestContext,
   type TestableOCPP20RequestService,
index ef3498f76bef00e4514f5d1bc635990c5cf70263..0985f864c723b4367343f3849d14ef13e6440315 100644 (file)
@@ -24,7 +24,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { createMockOCSPRequestData } from './OCPP20TestUtils.js'
 // Sample Base64 EXI request (mock - represents CertificateInstallationReq)
 const MOCK_EXI_REQUEST = 'SGVsbG8gV29ybGQgRVhJIFJlcXVlc3Q='
index cc4612e05313622b56a5fbc4a9826e0b1576d350..cb411a89603122794a416ddf1c364566d445bf07 100644 (file)
@@ -23,7 +23,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('M04 - LogStatusNotification', async () => {
   let station: ChargingStation
index 9b1ad5e68c5f85956ae93c7ea1385bd21a494006..9f8bdfd12b3a3a894ec3a5443c4514d630bbb69d 100644 (file)
@@ -22,7 +22,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('G01 - MeterValues', async () => {
   let station: ChargingStation
index f9c4dd95f73137be705aac3a654653997da7bc8c..03bc7dbf6a34bdb02197a65eb6eeda36a6522996 100644 (file)
@@ -32,7 +32,7 @@ import {
   TEST_CHARGING_STATION_BASE_NAME,
   TEST_FIRMWARE_VERSION,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('B07/B08 - NotifyReport', async () => {
   let testableService: TestableOCPP20RequestService
index e9c4b1d59d1ee65408a31e429744d36eae23d779..373967ed59c719abf818de270e5e7cf9ae5c4d19 100644 (file)
@@ -21,7 +21,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('A04 - SecurityEventNotification', async () => {
   let station: ChargingStation
index 4ad278bef37e90974c8a3d94b8352001f4aea45f..9f33b0bd565bd2c69d02824692e21666858bb0e3 100644 (file)
@@ -22,7 +22,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 const MOCK_ORGANIZATION_NAME = 'Test Organization Inc.'
 
index b8d36afe4bd5392b15d11deb1e0ff27aaeaa6cfd..a5d43d37a02121a664727eeab7eacc221ee517ec 100644 (file)
@@ -15,7 +15,7 @@
 import assert from 'node:assert/strict'
 import { afterEach, beforeEach, describe, it, mock } from 'node:test'
 
-import type { MockChargingStation } from '../../ChargingStationTestUtils.js'
+import type { MockChargingStation } from '../../helpers/StationHelpers.js'
 
 import { buildConfigKey } from '../../../../src/charging-station/index.js'
 import { OCPP20ResponseService } from '../../../../src/charging-station/ocpp/2.0/OCPP20ResponseService.js'
@@ -31,7 +31,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 /**
  * Create a mock station suitable for BootNotification response tests.
index b4d7cf2225931c2d856877691be97fb593298436..677af93ac3777e4855ecea5a03c8ca921d2fcdd1 100644 (file)
@@ -22,7 +22,7 @@ import {
   TEST_CHARGING_STATION_BASE_NAME,
   TEST_TOKEN_ISO14443,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { getTestAuthCache } from '../auth/helpers/MockFactories.js'
 
 await describe('C10 - TransactionEventResponse Cache Update', async () => {
index a370e835f5e47601850dd58437a2135cc3613c77..cb348d0c007daa3b2ea28046cd3d30bc5d6d4f5a 100644 (file)
@@ -6,7 +6,7 @@
 import assert from 'node:assert/strict'
 import { afterEach, beforeEach, describe, it, mock } from 'node:test'
 
-import type { MockChargingStation } from '../../ChargingStationTestUtils.js'
+import type { MockChargingStation } from '../../helpers/StationHelpers.js'
 
 import { OCPP20ResponseService } from '../../../../src/charging-station/ocpp/2.0/OCPP20ResponseService.js'
 import {
@@ -19,7 +19,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 /**
  * Create a mock station suitable for simple response handler tests.
index c992b0657a55dfdd74fdaec20a7a2dddb49b7049..daaec841d22d73f8c7fabbaba900df1065a5dc65 100644 (file)
@@ -32,7 +32,7 @@ import {
   TEST_CHARGING_STATION_BASE_NAME,
   TEST_TRANSACTION_UUID,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 interface TestableOCPP20ResponseService {
   handleResponseTransactionEvent: (
index bd88541b71a1125c0c804482bb5d6de7355c1c5d..502b019ced4304eb534daee1f130b105a7721d45 100644 (file)
@@ -27,7 +27,7 @@ import {
   TEST_CHARGING_STATION_BASE_NAME,
   TEST_TOKEN_ISO14443,
 } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { getTestAuthCache } from '../auth/helpers/MockFactories.js'
 
 await describe('OCPP20ServiceUtils.updateAuthorizationCache', async () => {
index 0b85e2210ba4be80512f0d22a07fb01e4c2b6734..16a4e337c8a8719ba0fbb15a37f448a563249fc8 100644 (file)
@@ -19,7 +19,7 @@ import {
 } from '../../../../src/types/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import { upsertConfigurationKey } from './OCPP20TestUtils.js'
 
 const DEFAULT_WAIT_MINIMUM_SECONDS = 30
index 1543f643ea8a237bb176024ae8e56e8c4d152869..32dcbd3fbc074f63d0e672aba867254142bbd856 100644 (file)
@@ -19,7 +19,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 
 await describe('OCPP20ServiceUtils', async () => {
   let mockStation: ChargingStation
index d8c93355bb1f6a8375b861ee3c5fd9f725afd106..5222feca55ecc9e3a007e99a052a85425a05066f 100644 (file)
@@ -50,7 +50,7 @@ import {
   withMockTimers,
 } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   type CapturedOCPPRequest,
   createMockStationWithRequestTracking,
index e9950d8eecae8179189fb69f200ba0d259e8c47a..cd9aac1c2ad34af9eb7608101dbbdb309a559cfe 100644 (file)
@@ -37,7 +37,7 @@ import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConsta
 import {
   createMockChargingStation,
   type MockChargingStation,
-} from '../../ChargingStationTestUtils.js'
+} from '../../helpers/StationHelpers.js'
 
 // ============================================================================
 // Testable Interfaces
index ead290f86b9483ecfeebddb63aaef85b2ef2a531..dda53fac55babd9a9d8dda058c06541f27989d1c 100644 (file)
@@ -37,7 +37,7 @@ import {
 import { Constants } from '../../../../src/utils/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   resetReportingValueSize,
   resetValueSizeLimits,
index 8154038c4fe4d4baf3461f0900cc157827b39bc5..439c6fc89838ce4b15f329ebc0a30f820f1bfe23 100644 (file)
@@ -27,7 +27,7 @@ import {
   setupConnectorWithTransaction,
   standardCleanup,
 } from '../../helpers/TestLifecycleHelpers.js'
-import { createMockChargingStation } from '../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../helpers/StationHelpers.js'
 import {
   createMockAuthorizationResult,
   createMockAuthService,
index 0255a3025f17835c7ea7fa51843913644cb72827..0ad928ccd02fae2303ef9f1e6f840faf7f392395 100644 (file)
@@ -32,7 +32,7 @@ import {
   TEST_TRANSACTION_ID,
   TEST_TRANSACTION_ID_STRING,
 } from '../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../helpers/StationHelpers.js'
 
 const energyTemplate: SampledValueTemplate = {
   measurand: MeterValueMeasurand.ENERGY_ACTIVE_IMPORT_REGISTER,
index 7cbcca277d06c4cca06f171fbce966f95ce55df9..f2a6649610fb337627af68521fd604e44221754c 100644 (file)
@@ -19,7 +19,7 @@ import {
 } from '../../../../src/charging-station/ocpp/auth/types/AuthTypes.js'
 import { OCPPVersion } from '../../../../src/types/index.js'
 import { standardCleanup } from '../../../helpers/TestLifecycleHelpers.js'
-import { createMockChargingStation } from '../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../helpers/StationHelpers.js'
 import {
   createMockAuthRequest,
   createMockIdentifier,
index 8ed50c5fed7c4287b25882b73e2e962bb6fa6e13..099b3b536b8e028c4095291bd960988f7c14c353 100644 (file)
@@ -12,7 +12,7 @@ import { AuthComponentFactory } from '../../../../../src/charging-station/ocpp/a
 import { OCPPVersion } from '../../../../../src/types/index.js'
 import { standardCleanup } from '../../../../helpers/TestLifecycleHelpers.js'
 import { TEST_AUTHORIZATION_TIMEOUT_MS } from '../../../ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../../../ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../../../helpers/StationHelpers.js'
 
 await describe('AuthComponentFactory', async () => {
   afterEach(() => {
index 0d11ab6878b393c06d269497795fd17f4019440c..e3a5f8b571d922fd6fff25ce3d2eb0f7302d1b04 100644 (file)
@@ -30,7 +30,7 @@ import { mock } from 'node:test'
 import type { ChargingStation } from '../../src/charging-station/index.js'
 import type { MockChargingStationOptions } from '../charging-station/helpers/StationHelpers.js'
 
-import { createMockChargingStation } from '../charging-station/ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../charging-station/helpers/StationHelpers.js'
 import { MockIdTagsCache, MockSharedLRUCache } from '../charging-station/mocks/MockCaches.js'
 
 /**
index 0a9eff82c4dce4c1172b542ce4e721499ecc7b96..0fefb46020748c0f60f878119d2625a4f038fb67 100644 (file)
@@ -24,7 +24,7 @@ import { Constants } from '../../src/utils/Constants.js'
 import {
   cleanupChargingStation,
   createMockChargingStation,
-} from '../charging-station/ChargingStationTestUtils.js'
+} from '../charging-station/helpers/StationHelpers.js'
 import { standardCleanup } from '../helpers/TestLifecycleHelpers.js'
 
 /**
index efd50a59dda220b6cdd54f460ce8fd654aa447b3..fab07259ba8f27b49b9b5c0d6a8a1c00234e0087 100644 (file)
@@ -24,7 +24,7 @@ import {
 } from '../../src/utils/ErrorUtils.js'
 import { logger } from '../../src/utils/index.js'
 import { TEST_CHARGING_STATION_BASE_NAME } from '../charging-station/ChargingStationTestConstants.js'
-import { createMockChargingStation } from '../charging-station/ChargingStationTestUtils.js'
+import { createMockChargingStation } from '../charging-station/helpers/StationHelpers.js'
 import {
   createConsoleMocks,
   createLoggerMocks,
index d4c988ef41ac5b731159da47570a38c846352623..532be1e290b7cded6eb96affb68df70851d46eca 100644 (file)
@@ -22,7 +22,7 @@ import {
 import {
   cleanupChargingStation,
   createMockChargingStation,
-} from '../charging-station/ChargingStationTestUtils.js'
+} from '../charging-station/helpers/StationHelpers.js'
 import { standardCleanup } from '../helpers/TestLifecycleHelpers.js'
 
 await describe('MessageChannelUtils', async () => {
index 89c171c824adfba41de21225eca70706c5442d93..cfcc50e420ab1339fac7fff39a574563fed1d3ad 100644 (file)
@@ -26,4 +26,5 @@ export {
   useExecuteAction,
   useTemplates,
   useUIClient,
+  validateUUID,
 } from './Utils'
index a24f7969a3920529343a7adc80255a0b1f1bc627..9ea0e5352ada544e7d1f12128d36f5e4f93279fe 100644 (file)
@@ -8,8 +8,7 @@ import { beforeEach, describe, expect, it, vi } from 'vitest'
 import type { UIClient } from '@/composables'
 
 import CSConnector from '@/components/charging-stations/CSConnector.vue'
-import { useUIClient } from '@/composables'
-import { EMPTY_VALUE_PLACEHOLDER } from '@/composables/Constants'
+import { EMPTY_VALUE_PLACEHOLDER, useUIClient } from '@/composables'
 import { OCPP16ChargePointStatus } from '@/types'
 
 import { toastMock } from '../setup'
index 900d472bf76bc0237dc1828b0fa57ea46f71bcdf..35cb78d32fca885fe0840648f7781aa1fa8658c5 100644 (file)
@@ -10,8 +10,7 @@ import type { ChargingStationData } from '@/types'
 
 import CSConnector from '@/components/charging-stations/CSConnector.vue'
 import CSData from '@/components/charging-stations/CSData.vue'
-import { useUIClient } from '@/composables'
-import { EMPTY_VALUE_PLACEHOLDER } from '@/composables/Constants'
+import { EMPTY_VALUE_PLACEHOLDER, useUIClient } from '@/composables'
 import { OCPPVersion } from '@/types'
 
 import { toastMock } from '../setup'
index 8779702182b67d1164b012de4d2f681a664a24a7..10caca441e65141c685ff701b8de8734df6e8ebc 100644 (file)
@@ -5,7 +5,7 @@
  */
 import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
 
-import { UIClient } from '@/composables/UIClient'
+import { UIClient } from '@/composables'
 import {
   AuthenticationType,
   OCPP20TransactionEventEnumType,
index d5fefcb7f57cdf6ba7eb3798c72c9324331eaf74..3637c5c3876a73529b787b7d6b3684b4edef7deb 100644 (file)
@@ -16,7 +16,7 @@ import {
   setToLocalStorage,
   useExecuteAction,
   validateUUID,
-} from '@/composables/Utils'
+} from '@/composables'
 
 import { toastMock } from '../setup'