Skip to content

Commit cb5944d

Browse files
committed
tests: use new more consistent supported type keywords from test framework
Signed-off-by: reubenmiller <[email protected]>
1 parent 00000fe commit cb5944d

File tree

8 files changed

+29
-29
lines changed

8 files changed

+29
-29
lines changed

tests/RobotFramework/requirements/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
paho-mqtt~=1.6.1
22
python-dotenv~=1.0.0
33
robotframework~=7.0.0
4-
robotframework-c8y @ git+https://github.com/thin-edge/robotframework-c8y.git@0.46.2
4+
robotframework-c8y @ git+https://github.com/thin-edge/robotframework-c8y.git@0.47.0
55
robotframework-aws @ git+https://github.com/thin-edge/[email protected]
66
robotframework-debuglibrary~=2.5.0
77
robotframework-jsonlibrary~=0.5

tests/RobotFramework/tests/config_management/inotify_crate.robot

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,14 @@ Configuration types should be detected on file change (without restarting servic
2929
${DEVICE_SN}= Setup
3030
Device Should Exist ${DEVICE_SN}
3131

32-
${supported_configs}= Should Support Configurations tedge-configuration-plugin includes=True
32+
${supported_configs}= Should Contain Supported Configuration Types tedge-configuration-plugin
3333
Should Not Contain ${supported_configs} example
3434

3535
Execute Command sudo rm -f /etc/tedge/plugins/tedge-configuration-plugin.toml
3636
Execute Command sudo printf '%s' "${toml}" > tedge-configuration-plugin.toml
3737
Execute Command sudo mv tedge-configuration-plugin.toml /etc/tedge/plugins/
3838

39-
${supported_configs}= Should Support Configurations
39+
${supported_configs}= Should Have Exact Supported Configuration Types
4040
... c8y-bridge.conf
4141
... tedge-configuration-plugin
4242
... mosquitto.conf

tests/RobotFramework/tests/cumulocity/configuration/configuration_operation.robot

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ Default plugin configuration
273273
Should Have MQTT Messages c8y/s/us message_contains=119, date_from=${timestamp}
274274

275275
Cumulocity.Set Device ${PARENT_SN}
276-
Cumulocity.Should Support Configurations
276+
Cumulocity.Should Have Exact Supported Configuration Types
277277
... tedge-configuration-plugin
278278
... tedge.toml
279279
... tedge-log-plugin
@@ -474,7 +474,7 @@ Update configuration plugin config via cloud
474474
[Arguments] ${test_desc} ${external_id}
475475
Log Test Description: ${test_desc}
476476
Cumulocity.Set Device ${external_id}
477-
Cumulocity.Should Support Configurations
477+
Cumulocity.Should Have Exact Supported Configuration Types
478478
... tedge-configuration-plugin
479479
... /etc/tedge/tedge.toml
480480
... harbor-certificate
@@ -488,7 +488,7 @@ Update configuration plugin config via cloud
488488
... file=${CURDIR}/tedge-configuration-plugin-updated.toml
489489
${operation}= Cumulocity.Set Configuration tedge-configuration-plugin url=${config_url}
490490
${operation}= Operation Should Be SUCCESSFUL ${operation}
491-
Cumulocity.Should Support Configurations
491+
Cumulocity.Should Have Exact Supported Configuration Types
492492
... tedge-configuration-plugin
493493
... /etc/tedge/tedge.toml
494494
... system.toml
@@ -500,7 +500,7 @@ Modify configuration plugin config via local filesystem modify inplace
500500
[Arguments] ${test_desc} ${device} ${external_id}
501501
Log Test Description: ${test_desc}
502502
Cumulocity.Set Device ${external_id}
503-
Cumulocity.Should Support Configurations
503+
Cumulocity.Should Have Exact Supported Configuration Types
504504
... tedge-configuration-plugin
505505
... /etc/tedge/tedge.toml
506506
... harbor-certificate
@@ -510,7 +510,7 @@ Modify configuration plugin config via local filesystem modify inplace
510510
... CONFIG1_BINARY
511511
ThinEdgeIO.Set Device Context ${device}
512512
ThinEdgeIO.Execute Command sed -i 's/CONFIG1/CONFIG3/g' /etc/tedge/plugins/tedge-configuration-plugin.toml
513-
Cumulocity.Should Support Configurations
513+
Cumulocity.Should Have Exact Supported Configuration Types
514514
... tedge-configuration-plugin
515515
... /etc/tedge/tedge.toml
516516
... harbor-certificate
@@ -526,7 +526,7 @@ Modify configuration plugin config via local filesystem overwrite
526526
Log Test Description: ${test_desc}
527527
ThinEdgeIO.Set Device Context ${device}
528528
Cumulocity.Set Device ${external_id}
529-
Cumulocity.Should Support Configurations
529+
Cumulocity.Should Have Exact Supported Configuration Types
530530
... tedge-configuration-plugin
531531
... /etc/tedge/tedge.toml
532532
... harbor-certificate
@@ -537,7 +537,7 @@ Modify configuration plugin config via local filesystem overwrite
537537
${NEW_CONFIG}= ThinEdgeIO.Execute Command
538538
... sed 's/CONFIG1/CONFIG3/g' /etc/tedge/plugins/tedge-configuration-plugin.toml
539539
ThinEdgeIO.Execute Command echo "${NEW_CONFIG}" > /etc/tedge/plugins/tedge-configuration-plugin.toml
540-
Cumulocity.Should Support Configurations
540+
Cumulocity.Should Have Exact Supported Configuration Types
541541
... tedge-configuration-plugin
542542
... /etc/tedge/tedge.toml
543543
... harbor-certificate
@@ -553,7 +553,7 @@ Update configuration plugin config via local filesystem copy
553553
Log Test Description: ${test_desc}
554554
ThinEdgeIO.Set Device Context ${device}
555555
Cumulocity.Set Device ${external_id}
556-
Cumulocity.Should Support Configurations
556+
Cumulocity.Should Have Exact Supported Configuration Types
557557
... tedge-configuration-plugin
558558
... /etc/tedge/tedge.toml
559559
... harbor-certificate
@@ -564,7 +564,7 @@ Update configuration plugin config via local filesystem copy
564564
Transfer To Device ${CURDIR}/tedge-configuration-plugin-updated.toml /etc/tedge/plugins/
565565
Execute Command
566566
... cp /etc/tedge/plugins/tedge-configuration-plugin-updated.toml /etc/tedge/plugins/tedge-configuration-plugin.toml
567-
Cumulocity.Should Support Configurations
567+
Cumulocity.Should Have Exact Supported Configuration Types
568568
... tedge-configuration-plugin
569569
... /etc/tedge/tedge.toml
570570
... system.toml
@@ -579,7 +579,7 @@ Update configuration plugin config via local filesystem move (different director
579579
Log Test Description: ${test_desc}
580580
ThinEdgeIO.Set Device Context ${device}
581581
Cumulocity.Set Device ${external_id}
582-
Cumulocity.Should Support Configurations
582+
Cumulocity.Should Have Exact Supported Configuration Types
583583
... tedge-configuration-plugin
584584
... /etc/tedge/tedge.toml
585585
... harbor-certificate
@@ -590,7 +590,7 @@ Update configuration plugin config via local filesystem move (different director
590590
Transfer To Device ${CURDIR}/tedge-configuration-plugin-updated.toml /etc/
591591
Execute Command
592592
... mv /etc/tedge-configuration-plugin-updated.toml /etc/tedge/plugins/tedge-configuration-plugin.toml
593-
Cumulocity.Should Support Configurations
593+
Cumulocity.Should Have Exact Supported Configuration Types
594594
... tedge-configuration-plugin
595595
... /etc/tedge/tedge.toml
596596
... system.toml
@@ -605,7 +605,7 @@ Update configuration plugin config via local filesystem move (same directory)
605605
Log Test Description: ${test_desc}
606606
ThinEdgeIO.Set Device Context ${device}
607607
Cumulocity.Set Device ${external_id}
608-
Cumulocity.Should Support Configurations
608+
Cumulocity.Should Have Exact Supported Configuration Types
609609
... tedge-configuration-plugin
610610
... /etc/tedge/tedge.toml
611611
... harbor-certificate
@@ -616,7 +616,7 @@ Update configuration plugin config via local filesystem move (same directory)
616616
Transfer To Device ${CURDIR}/tedge-configuration-plugin-updated.toml /etc/tedge/plugins/
617617
Execute Command
618618
... mv /etc/tedge/plugins/tedge-configuration-plugin-updated.toml /etc/tedge/plugins/tedge-configuration-plugin.toml
619-
Cumulocity.Should Support Configurations
619+
Cumulocity.Should Have Exact Supported Configuration Types
620620
... tedge-configuration-plugin
621621
... /etc/tedge/tedge.toml
622622
... system.toml

tests/RobotFramework/tests/cumulocity/configuration/configuration_with_file_transfer_https.robot

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ Get Configuration Should Fail
110110
Update Configuration Should Fail
111111
[Arguments] ${failure_reason} ${external_id}
112112
Cumulocity.Set Device ${external_id}
113-
Cumulocity.Should Support Configurations
113+
Cumulocity.Should Have Exact Supported Configuration Types
114114
... tedge-configuration-plugin
115115
... /etc/tedge/tedge.toml
116116
... harbor-certificate
@@ -124,7 +124,7 @@ Update Configuration Should Fail
124124
... file=${CURDIR}/tedge-configuration-plugin-updated.toml
125125
${operation}= Cumulocity.Set Configuration tedge-configuration-plugin ${config_url}
126126
Operation Should Be FAILED ${operation} failure_reason=${failure_reason} timeout=120
127-
Cumulocity.Should Support Configurations
127+
Cumulocity.Should Have Exact Supported Configuration Types
128128
... tedge-configuration-plugin
129129
... /etc/tedge/tedge.toml
130130
... harbor-certificate
@@ -136,7 +136,7 @@ Update Configuration Should Fail
136136
Update Configuration Should Succeed
137137
[Arguments] ${external_id}
138138
Cumulocity.Set Device ${external_id}
139-
Cumulocity.Should Support Configurations
139+
Cumulocity.Should Have Exact Supported Configuration Types
140140
... tedge-configuration-plugin
141141
... /etc/tedge/tedge.toml
142142
... harbor-certificate
@@ -150,7 +150,7 @@ Update Configuration Should Succeed
150150
... file=${CURDIR}/tedge-configuration-plugin-updated.toml
151151
${operation}= Cumulocity.Set Configuration tedge-configuration-plugin ${config_url}
152152
Operation Should Be SUCCESSFUL ${operation} timeout=120
153-
Cumulocity.Should Support Configurations
153+
Cumulocity.Should Have Exact Supported Configuration Types
154154
... tedge-configuration-plugin
155155
... /etc/tedge/tedge.toml
156156
... system.toml

tests/RobotFramework/tests/cumulocity/log/log_operation.robot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ Default plugin configuration
128128

129129
Should Have MQTT Messages c8y/s/us message_contains=118, date_from=${timestamp}
130130
Cumulocity.Set Device ${DEVICE_SN}
131-
Cumulocity.Should Support Log File Types software-management
131+
Cumulocity.Should Have Exact Supported Log Types software-management
132132

133133
${start_timestamp}= Get Current Date UTC -24 hours result_format=%Y-%m-%dT%H:%M:%S+0000
134134
${end_timestamp}= Get Current Date UTC +60 seconds result_format=%Y-%m-%dT%H:%M:%S+0000

tests/RobotFramework/tests/cumulocity/log/log_operation_plugins.robot

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Test Tags theme:c8y theme:log
1414

1515
*** Test Cases ***
1616
Log operation journald plugin
17-
Should Support Log File Types tedge-agent::journald includes=${True}
17+
Should Contain Supported Log Types tedge-agent::journald
1818
${start_timestamp}= Get Current Date UTC -1 hours result_format=%Y-%m-%dT%H:%M:%S+0000
1919
${end_timestamp}= Get Current Date UTC +1 hours result_format=%Y-%m-%dT%H:%M:%S+0000
2020
${operation}= Create Log Request Operation
@@ -35,7 +35,7 @@ Supported log types updated on software update
3535
... topic=te/device/main///cmd/log_upload
3636
... date_from=${start_time}
3737
... message_contains=cron::journald
38-
Should Support Log File Types cron::journald includes=${True}
38+
Should Contain Supported Log Types cron::journald
3939

4040
Supported log types updated on config update
4141
[Documentation] Updating any configuration should trigger supported log types update
@@ -53,7 +53,7 @@ Supported log types updated on config update
5353
... message_contains=software-management
5454

5555
Log operation journald plugin can return logs for all units
56-
Should Support Log File Types all-units::journald includes=${True}
56+
Should Contain Supported Log Types all-units::journald
5757
${start_timestamp}= Get Current Date UTC -1 hours result_format=%Y-%m-%dT%H:%M:%S+0000
5858
${end_timestamp}= Get Current Date UTC +1 hours result_format=%Y-%m-%dT%H:%M:%S+0000
5959
${operation}= Create Log Request Operation
@@ -139,7 +139,7 @@ Dynamic plugin install and remove
139139
... ${CURDIR}/plugins/dummy_plugin
140140
... /usr/share/tedge/log-plugins/dummy_plugin
141141
Execute Command chmod +x /usr/share/tedge/log-plugins/dummy_plugin
142-
Should Support Log File Types dummy_log::dummy_plugin includes=${True}
142+
Should Contain Supported Log Types dummy_log::dummy_plugin
143143

144144
${start_timestamp}= Get Current Date UTC -1 hours result_format=%Y-%m-%dT%H:%M:%S+0000
145145
${end_timestamp}= Get Current Date UTC +1 hours result_format=%Y-%m-%dT%H:%M:%S+0000
@@ -171,7 +171,7 @@ Overriding a log plugin
171171
Execute Command
172172
... cmd=echo 'tedge ALL = (ALL) NOPASSWD:SETENV: /usr/local/tedge/log-plugins/[a-zA-Z0-9]*' | sudo tee -a /etc/sudoers.d/tedge
173173
Restart Service tedge-agent
174-
Should Support Log File Types fake_log::fake_plugin includes=${True}
174+
Should Contain Supported Log Types fake_log::fake_plugin
175175
# Override the fake plugin with a dummy plugin
176176
ThinEdgeIO.Transfer To Device
177177
... ${CURDIR}/plugins/dummy_plugin
@@ -180,7 +180,7 @@ Overriding a log plugin
180180
${dummy_types}= Execute Command /usr/local/tedge/log-plugins/fake_plugin list
181181
Should Be Equal ${dummy_types} dummy_log strip_spaces=${True}
182182
# The fake plugin has been overridden
183-
Should Support Log File Types dummy_log::fake_plugin includes=${True}
183+
Should Contain Supported Log Types dummy_log::fake_plugin
184184

185185
${start_timestamp}= Get Current Date UTC -1 hours result_format=%Y-%m-%dT%H:%M:%S+0000
186186
${end_timestamp}= Get Current Date UTC +1 hours result_format=%Y-%m-%dT%H:%M:%S+0000

tests/RobotFramework/tests/cumulocity/log/workflow/log_workflow.robot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Custom log workflow with pre-processor
1616
[Documentation] Use a custom log_upload workflow to support command based logs. It uses a custom preprocessor
1717
... step to run a custom command (via the log_upload.sh script), which can be used to read logs from any source
1818
... (sqlite in this example)
19-
Cumulocity.Should Support Log File Types sqlite includes=${True}
19+
Cumulocity.Should Contain Supported Log Types sqlite
2020

2121
${start_timestamp}= Get Current Date UTC -24 hours result_format=%Y-%m-%dT%H:%M:%S+0000
2222
${end_timestamp}= Get Current Date UTC +60 seconds result_format=%Y-%m-%dT%H:%M:%S+0000

tests/RobotFramework/tests/cumulocity/supported_operations/service-supported-ops.robot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Services Can Register Supported Operations
1919
... tedge mqtt pub -q 1 --retain te/device/main/service/app1/cmd/log_upload '{"types": ["systemd"]}'
2020

2121
Cumulocity.Should Contain Supported Operations c8y_Restart c8y_LogfileRequest
22-
Cumulocity.Should Support Log File Types systemd
22+
Cumulocity.Should Have Exact Supported Log Types systemd
2323

2424
Services Can Receive Operations
2525
# NOTE: The c8y_Restart operation is used to check the handling of operation status updates because it

0 commit comments

Comments
 (0)