Skip to content

Add missing E2E test coverage #358

Description

@noraeb

Following the integration test coverage review, we identified several user flows in CoMPAS that currently have no E2E test coverage in compas-deployment/integration-testing.

Covered

Area Flow Happy path Negative path Suite
Open Open project from local file TestSuite001
Open Open local file + add to CoMPAS (REST) TestSuite001
Open Open local file + add to CoMPAS (WebSocket) TestSuite001
Open Open project from CoMPAS (REST) TestSuite001
Open Open project from CoMPAS (WebSocket) TestSuite001
Save Open from CoMPAS (REST) → save to local file TestSuite001
Save Save existing project as new project TestSuite001
Save Save local project as new version of existing project TestSuite001
Save Save to CoMPAS (REST) with invalid name TestSuite001
Save Save to CoMPAS (WebSocket) with invalid name TestSuite001
Versions Versions tab shows zero versions TestSuite002
Versions Versions tab shows one version TestSuite002
Versions Every save creates a new version TestSuite002
Versions Add a new version from a local file TestSuite002
Versions Restore first version from list TestSuite002
Versions Delete first version from list TestSuite002
Versions Delete all versions TestSuite002
Versions Compare current version vs. CoMPAS version TestSuite002
Versions Compare current version, wrong selection count TestSuite002
Versions Compare two versions from CoMPAS TestSuite002
Versions Compare versions, wrong selection count TestSuite002
CIM Mapping Create project from CIM file TestSuite003
CIM Mapping Create project from invalid CIM filename TestSuite003
Auto-Alignment Execute for single substation TestSuite004
Auto-Alignment Execute for multiple substations TestSuite004
Auto-Alignment Incomplete configuration TestSuite004
Validation SCL validator (WebSocket) — OCL errors ⚠️ (only failure asserted) TestSuite005
Validation SCL validator (REST) — OCL errors ⚠️ (only failure asserted) TestSuite005
Validation SCL validator (WebSocket) — XSD errors ⚠️ (only failure asserted) TestSuite005
Validation SCL validator (REST) — XSD errors ⚠️ (only failure asserted) TestSuite005

Gaps

Area Feature Frontend source Why it matters
Merge Merge two SCL documents src/menu/CompasMerge.ts Data-destructive operation on production configs; no safety net at all
Session Session expiring mid-edit (warning dialog) src/compas/CompasSessionExpiringDialog.ts Long editing sessions are normal for this tool; silent failure risks lost work
Session Session expired (forced logout) src/compas/CompasSessionExpiredDialog.ts Same as above
Backend resilience Save when SCL Data Service is unreachable/errors (5xx, timeout) n/a (only client-side validation tested) Realistic failure mode in any deployed environment; only "bad filename" is tested today
Backend resilience Open when SCL Data Service is unreachable/errors n/a Same as above, on read path
Import Import IEDs src/menu/CompasImportIEDs.ts Relatively complex feature, that is currently untested
Import Import from external API src/menu/CompasImportFromApi.ts, src/compas/CompasImportFromApi.ts Check: is this feature used by anyone?
Compare Compare IED src/menu/CompasCompareIED.ts Different mechanism from version-compare (already tested); untested
Update Update Substation src/menu/CompasUpdateSubstation.ts No coverage
Validation Valid file passes validation (explicit happy-path assertion) n/a Current tests only assert the failure branch of OCL/XSD checks
Validation Malformed / not-well-formed XML input n/a Different failure class than "schema-valid but semantically wrong"
Auto-Alignment Malformed alignment input (vs. "incomplete config") n/a Different failure class than the one already tested
Auto-Alignment Alignment run that produces zero changes n/a Silent no-op vs. crash are different bugs; unverified
Scale Open / align / validate a large substation file n/a Performance/timeout boundary unverified
SCL types SCL type list / select src/compas/CompasSclTypeList.ts, CompasSclTypeSelect.ts Same as above

Acceptance Criteria

  • New test cases added for all missing flows
  • Tests run green in CI across configured browsers
  • Coverage matrix updated to reflect new "Covered" status

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions