Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,13 @@ For information about CoMPAS go to this [site](https://com-pas.github.io/).

## Release notes

### Release 0.14.1

Next release for testing the CoMPAS System with all components.
- [OpenSCD CoMPAS Edition](https://github.com/com-pas/compas-open-scd) (Version 0.24.0.4):
- Save current project as version to an existing SCL File in CoMPAS;
- Switch to other base image (Bitnami) for container image;

### Release 0.14.0

Next release for testing the CoMPAS System with all components.
Expand Down
16 changes: 5 additions & 11 deletions compas/docker-compose-basex.yml
Original file line number Diff line number Diff line change
Expand Up @@ -144,15 +144,12 @@ services:
open-scd:
labels:
compas: true
image: "lfenergy/compas-open-scd:v0.24.0.3"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost/"]
interval: 30s
timeout: 10s
retries: 5
image: "lfenergy/compas-open-scd:v0.24.0.4"
depends_on:
- scl-data-service
- cim-mapping
- scl-auto-alignment
- scl-validator

reverse-proxy:
labels:
Expand All @@ -163,15 +160,12 @@ services:
COMPAS_HOSTNAME: ${COMPAS_HOSTNAME}
ports:
- "80:80"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost/"]
interval: 30s
timeout: 10s
retries: 5
depends_on:
- keycloak
- scl-data-service
- cim-mapping
- scl-auto-alignment
- scl-validator
- open-scd

volumes:
Expand Down
14 changes: 2 additions & 12 deletions compas/docker-compose-postgresql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ services:
postgresql:
labels:
compas: true
image: "postgres:14.4"
image: "postgres:14.5"
ports:
- "5432:5432"
environment:
Expand Down Expand Up @@ -151,12 +151,7 @@ services:
open-scd:
labels:
compas: true
image: "lfenergy/compas-open-scd:v0.24.0.3"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost/"]
interval: 30s
timeout: 10s
retries: 5
image: "lfenergy/compas-open-scd:v0.24.0.4"
depends_on:
- scl-data-service
- cim-mapping
Expand All @@ -172,11 +167,6 @@ services:
COMPAS_HOSTNAME: ${COMPAS_HOSTNAME}
ports:
- "80:80"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost/"]
interval: 30s
timeout: 10s
retries: 5
depends_on:
- keycloak
- scl-data-service
Expand Down
2 changes: 1 addition & 1 deletion compas/reverse-proxy/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ http {
# Added Header back to browser to get JWT Content for Debugging, should not do this in production.
add_header X-Debug-Bearer "Bearer ${access_token}" always;

proxy_pass http://open-scd:80/;
proxy_pass http://open-scd:8080/;

proxy_set_header Host $http_host;
proxy_cache_bypass $http_upgrade;
Expand Down
60 changes: 39 additions & 21 deletions integration-testing/TestSuite001-basic-compas.robot
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,24 @@
*** Settings ***
Documentation Basic test cases for opening and saving SCL files to/from Local File and CoMPAS.
Resource ./include/general-compas.robot
Resource include/general-compas.robot

Test Setup Initialize and Start OpenSCD
Test Teardown Make screenshot and Stop OpenSCD

*** Test Cases ***
TestCase001-01
[Documentation] Open project from Local File
Set Test Variable ${sclname} MiniGrid
Set Test Variable ${scltype} SCD

Open Menu Open project
Open local file ${sclname} ${scltype}
Open local file MiniGrid SCD

Select Tab Substation
Get Text ${substation-editor-selector} section > h1:has-text("Sub1")

TestCase001-02
[Documentation] Open project from Local File and Add to CoMPAS
Set Test Variable ${sclname} MiniGrid
Set Test Variable ${scltype} SCD

Open Menu Open project
Open local file ${sclname} ${scltype}
Open local file MiniGrid SCD

Set Test Variable ${sclname} ${TEST NAME}
Set Test Variable ${scltype} CID
Expand All @@ -41,11 +36,8 @@ TestCase001-02
TestCase001-03
[Documentation] Open project from CoMPAS
# First we need to add a project to CoMPAS to be able to open it from CoMPAS.
Set Test Variable ${sclname} MiniGrid
Set Test Variable ${scltype} SCD

Open Menu Open project
Open local file ${sclname} ${scltype}
Open local file MiniGrid SCD

Set Test Variable ${sclname} ${TEST NAME}
Set Test Variable ${scltype} CID
Expand All @@ -65,11 +57,8 @@ TestCase001-03
TestCase001-04
[Documentation] Open project from CoMPAS and Save to Local File
# First we need to add a project to CoMPAS to be able to open it from CoMPAS.
Set Test Variable ${sclname} MiniGrid
Set Test Variable ${scltype} SCD

Open Menu Open project
Open local file ${sclname} ${scltype}
Open local file MiniGrid SCD

Set Test Variable ${sclname} ${TEST NAME}
Set Test Variable ${scltype} CID
Expand All @@ -81,13 +70,43 @@ TestCase001-04
Save to local file ${sclname} ${scltype}

TestCase001-05
[Documentation] Save a existing project from CoMPAS as new project
# First we need to add a project to CoMPAS to be able to open it from CoMPAS.
Open Menu Open project
Open local file MiniGrid SCD

Set Test Variable ${sclname} ${TEST NAME}
Set Test Variable ${scltype} CID

Open Menu Save project
Add to CoMPAS MiniGrid ${sclname} ${scltype} 1.0.0

Open Menu Save project as
Save as to CoMPAS ${sclname}-${current-date}-1.0.0 ${sclname}-as ${scltype} 1.0.0

TestCase001-06
[Documentation] Save local project as new version to existing project in CoMPAS
# First we need to add a project to CoMPAS to be able to open it from CoMPAS.
Open Menu Open project
Open local file MiniGrid SCD

Set Test Variable ${sclname} ${TEST NAME}
Set Test Variable ${scltype} CID

Open Menu Save project
Add to CoMPAS MiniGrid ${sclname} ${scltype} 1.0.0

Open Menu Open project
Open local file MiniGrid SCD

Open Menu Save as version
Save version to CoMPAS MINOR ${sclname} ${scltype} 1.1.0

TestCase001-10
[Documentation] Trying saving local file to CoMPAS with invalid name
# First we will open the local file to be saved.
Set Test Variable ${sclname} MiniGrid
Set Test Variable ${scltype} SCD

Open Menu Open project
Open local file ${sclname} ${scltype}
Open local file MiniGrid SCD

# Try saving the file with a invalid name
Set Test Variable ${sclname} invalid/*name
Expand All @@ -107,4 +126,3 @@ TestCase001-05
# Check if the expected error message is found
Set Test Variable ${secondaryMessage} ApplicationError: Name is not a correct name to be used later as filename. (CORE-8000) (400)
Check CoMPAS Error ${secondaryMessage}

41 changes: 41 additions & 0 deletions integration-testing/include/general-compas.robot
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Resource ./general-openscd.robot
Open from CoMPAS
[Arguments] ${name} ${type} ${expectedVersion}
Click mwc-dialog#compas-open-dlg > compas-open compas-scltype-list > mwc-list > mwc-list-item >> span:has-text("${type.upper()}")
Select label mwc-dialog#compas-open-dlg > compas-open ${type}_${current-date}
Click mwc-dialog#compas-open-dlg > compas-open compas-scl-list > filtered-list > mwc-list-item:has-text("${name}-${current-date}")
Wait for dialog is closed
Close Menu
Expand All @@ -24,21 +25,49 @@ Add to CoMPAS
Fill Text mwc-dialog#compas-save-dlg > compas-save mwc-textfield#name label > input ${name}-${current-date}
Click mwc-dialog#compas-save-dlg > compas-save compas-scltype-select mwc-select
Click mwc-dialog#compas-save-dlg > compas-save compas-scltype-select mwc-select > mwc-list-item[value="${type.upper()}"]
Add label mwc-dialog#compas-save-dlg > compas-save ${type}_${current-date}
Click mwc-dialog#compas-save-dlg > mwc-button[slot="primaryAction"] > button
Wait for dialog is closed
Close Menu
# check if the title (filename) changed to the new expected one.
Check Title Filename ${name}-${current-date}-${expectedVersion} ${type}

Save as to CoMPAS
[Arguments] ${initialValue} ${name} ${type} ${expectedVersion}
# Make sure the initial value is entered. so we can continue.
Get Text mwc-dialog#compas-save-as-dlg > compas-save mwc-textfield#name label > input == ${initialValue}
Fill Text mwc-dialog#compas-save-as-dlg > compas-save mwc-textfield#name label > input ${name}-${current-date}
Click mwc-dialog#compas-save-as-dlg > compas-save compas-scltype-select mwc-select
Click mwc-dialog#compas-save-as-dlg > compas-save compas-scltype-select mwc-select > mwc-list-item[value="${type.upper()}"]
Add label mwc-dialog#compas-save-as-dlg > compas-save ${type}_as_${current-date}
Click mwc-dialog#compas-save-as-dlg > mwc-button[slot="primaryAction"] > button
Wait for dialog is closed
Close Menu
# check if the title (filename) changed to the new expected one.
Check Title Filename ${name}-${current-date}-${expectedVersion} ${type}

Update in CoMPAS
[Arguments] ${changeType} ${name} ${type} ${expectedVersion}
Click mwc-dialog#compas-save-dlg > compas-save compas-changeset-radiogroup mwc-list > mwc-radio-list-item[value="${changeType.upper()}"]
Add label mwc-dialog#compas-save-dlg > compas-save ${type}_${current-date}_${expectedVersion.replace('.', '')}
Click mwc-dialog#compas-save-dlg > mwc-button[slot="primaryAction"] > button
Wait for dialog is closed
Close Menu
# check if the title (filename) changed to the new expected one.
Check Title Filename ${name}-${current-date}-${expectedVersion} ${type}

Save version to CoMPAS
[Arguments] ${changeType} ${name} ${type} ${expectedVersion}
Click mwc-dialog#compas-save-as-version-dlg > compas-open compas-scltype-list > mwc-list > mwc-list-item >> span:has-text("${type.upper()}")
Click mwc-dialog#compas-save-as-version-dlg > compas-open compas-scl-list > filtered-list > mwc-list-item:has-text("${name}-${current-date}")
Click mwc-dialog#compas-save-as-version-dlg > compas-save compas-changeset-radiogroup mwc-list > mwc-radio-list-item[value="${changeType.upper()}"]
Click mwc-dialog#compas-save-as-version-dlg > mwc-button[slot="primaryAction"] > button
Wait for dialog is closed
Close Menu
# check if the title (filename) changed to the new expected one.
Check Title Filename ${name}-${current-date}-${expectedVersion} ${type}


Change Websockets setting
[Arguments] ${checked}
Open Menu CoMPAS Settings
Expand All @@ -55,3 +84,15 @@ Check CoMPAS Error
[Arguments] ${secondaryMessage}
Set Test Variable ${primaryMessage} Error communicating with CoMPAS Ecosystem
Check Log ${primaryMessage} ${secondaryMessage}

Add label
[Arguments] ${dialog} ${label}
Fill Text ${dialog} compas-labels-field wizard-textfield#newLabel label > input ${label}
Click ${dialog} compas-labels-field mwc-icon-button[icon="new_label"] > button

Select label
[Arguments] ${dialog} ${label}
Click ${dialog} compas-scl-list oscd-filter-button#labelsFilter > mwc-icon-button > button
Click ${dialog} compas-scl-list oscd-filter-button#labelsFilter > mwc-dialog#filterDialog mwc-formfield > mwc-checkbox
Click ${dialog} compas-scl-list oscd-filter-button#labelsFilter > mwc-check-list-item[value="${label}"]
Click ${dialog} compas-scl-list oscd-filter-button#labelsFilter > mwc-dialog#filterDialog > mwc-button[slot="primaryAction"] > button