Skip to content

Commit

Permalink
Merge pull request #45 from thin-edge/test-container-monitoring
Browse files Browse the repository at this point in the history
test: add coverage for service creation after installing a container
  • Loading branch information
reubenmiller authored Nov 21, 2024
2 parents df17fe4 + 5c62642 commit 4e2a310
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ RUN wget -O - https://thin-edge.io/install-services.sh | sh -s -- s6_overlay \
# Set permissions of all files under /etc/tedge
# TODO: Can thin-edge.io set permissions during installation?
RUN chown -R tedge:tedge /etc/tedge \
&& echo "tedge ALL = (ALL) NOPASSWD: /usr/bin/tedge, /etc/tedge/sm-plugins/[a-zA-Z0-9]*, /bin/sync, /sbin/init, /usr/bin/tedgectl, /usr/bin/docker, /usr/bin/tedge-container" >/etc/sudoers.d/tedge
&& echo "tedge ALL = (ALL) NOPASSWD: /usr/bin/tedge, /etc/tedge/sm-plugins/[a-zA-Z0-9]*, /bin/sync, /sbin/init, /usr/bin/tedgectl, /usr/bin/docker, /usr/bin/tedge-container, /bin/kill" >/etc/sudoers.d/tedge
# Custom init. scripts - e.g. write env variables data to files
COPY cont-init.d/* /etc/cont-init.d/

Expand Down
1 change: 1 addition & 0 deletions tests/main/operations.robot
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ Install application using docker compose
${software}= Device Should Have Installed Software
... {"name": "nodered-instance1", "version": "1.0.0", "softwareType": "container-group"}

Cumulocity.Should Have Services service_type=container-group name=nodered-instance1@node-red status=up max_count=1

Get Container Logs
${operation}= Cumulocity.Get Log File container search_text=tedge maximum_lines=100
Expand Down

1 comment on commit 4e2a310

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Robot Results

✅ Passed ❌ Failed ⏭️ Skipped Total Pass % ⏱️ Duration
13 0 1 13 100 1m22.960548999s

Passed Tests

Name ⏱️ Duration Suite
Grace period to allow container to startup 5.002 s Operations
tedge-container-plugin service is up 0.166 s Operations
Get Logfile Request 2.513 s Operations
Get Configuration File 5.005 s Operations
Execute Shell Command 2.503 s Operations
Install application using docker compose 16.014 s Operations
Get Container Logs 2.504 s Operations
Trigger self update via local command 12.230 s Self-Update
Self update should only update if there is a new image 4.688 s Self-Update
Self update using software update operation 29.149 s Self-Update
Cloud Connection is Online 0.176 s Telemetry
Service status 0.333 s Telemetry
Sends measurements 2.675 s Telemetry

Please sign in to comment.