Skip to content

Commit

Permalink
skip powershell tests which are dependent on other resources
Browse files Browse the repository at this point in the history
  • Loading branch information
reubenmiller committed Apr 27, 2024
1 parent d21ca0d commit abb5d34
Show file tree
Hide file tree
Showing 18 changed files with 63 additions and 30 deletions.
21 changes: 14 additions & 7 deletions api/spec/json/applicationVersions.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
"powershell": [
{
"description": "Get application versions",
"command": "Get-ApplicationVersionCollection -Application 1234"
"command": "Get-ApplicationVersionCollection -Application 1234",
"skipTest": true
}
],
"go": [
Expand Down Expand Up @@ -72,11 +73,13 @@
"powershell": [
{
"description": "Get application version by tag",
"command": "Get-ApplicationVersion -Application 1234 -Tag tag1"
"command": "Get-ApplicationVersion -Application 1234 -Tag tag1",
"skipTest": true
},
{
"description": "Get application version by version name",
"command": "Get-ApplicationVersion -Application 1234 -Version 1.0"
"command": "Get-ApplicationVersion -Application 1234 -Version 1.0",
"skipTest": true
}
],
"go": [
Expand Down Expand Up @@ -209,11 +212,13 @@
"powershell": [
{
"description": "Delete application version by tag",
"command": "Remove-ApplicationVersion -Application 1234 -Tag tag1"
"command": "Remove-ApplicationVersion -Application 1234 -Tag tag1",
"skipTest": true
},
{
"description": "Delete application version by version name",
"command": "Remove-ApplicationVersion -Application 1234 -Version 1.0"
"command": "Remove-ApplicationVersion -Application 1234 -Version 1.0",
"skipTest": true
}
],
"go": [
Expand Down Expand Up @@ -269,11 +274,13 @@
"powershell": [
{
"description": "Get application version by tag",
"command": "Update-ApplicationVersionTag -Application 1234 -Tag tag1"
"command": "Update-ApplicationVersionTag -Application 1234 -Tag tag1",
"skipTest": true
},
{
"description": "Get application version by version name",
"command": "Update-ApplicationVersionTag -Application 1234 -Version 1.0"
"command": "Update-ApplicationVersionTag -Application 1234 -Version 1.0",
"skipTest": true
}
],
"go": [
Expand Down
3 changes: 2 additions & 1 deletion api/spec/json/notification2Subscriptions.json
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,8 @@
"powershell": [
{
"description": "Delete a subscription associated with a device",
"command": "Remove-Notification2SubscriptionBySource -Device 12345"
"command": "Remove-Notification2SubscriptionBySource -Device 12345",
"skipTest": true
}
],
"go": [
Expand Down
3 changes: 2 additions & 1 deletion api/spec/json/uiPlugins.json
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,8 @@
"powershell": [
{
"description": "Get ui plugin",
"command": "Get-UIPlugin -Id 1234"
"command": "Get-UIPlugin -Id 1234",
"skipTest": true
}
],
"go": [
Expand Down
18 changes: 12 additions & 6 deletions api/spec/json/uiPluginsVersions.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
"powershell": [
{
"description": "Get plugin versions",
"command": "Get-UIPluginVersionCollection -Plugin 1234"
"command": "Get-UIPluginVersionCollection -Plugin 1234",
"skipTest": true
}
],
"go": [
Expand Down Expand Up @@ -73,11 +74,13 @@
"powershell": [
{
"description": "Get plugin version by tag",
"command": "Get-UIPluginVersion -Plugin 1234 -Tag tag1"
"command": "Get-UIPluginVersion -Plugin 1234 -Tag tag1",
"skipTest": true
},
{
"description": "Get plugin version by version name",
"command": "Get-UIPluginVersion -Plugin 1234 -Version 1.0"
"command": "Get-UIPluginVersion -Plugin 1234 -Version 1.0",
"skipTest": true
}
],
"go": [
Expand Down Expand Up @@ -213,11 +216,13 @@
"powershell": [
{
"description": "Delete plugin version by tag",
"command": "Remove-UIPluginVersion -Plugin 1234 -Tag tag1"
"command": "Remove-UIPluginVersion -Plugin 1234 -Tag tag1",
"skipTest": true
},
{
"description": "Delete plugin version by version name",
"command": "Remove-UIPluginVersion -Plugin 1234 -Version 1.0"
"command": "Remove-UIPluginVersion -Plugin 1234 -Version 1.0",
"skipTest": true
}
],
"go": [
Expand Down Expand Up @@ -285,7 +290,8 @@
"powershell": [
{
"description": "Replace tags assigned to a version of a plugin",
"command": "Update-UIPluginVersion -Plugin 1234 -Version 1.0 -Tags tag1,latest"
"command": "Update-UIPluginVersion -Plugin 1234 -Version 1.0 -Tags tag1,latest",
"skipTest": true
}
],
"go": [
Expand Down
9 changes: 9 additions & 0 deletions api/spec/yaml/applicationVersions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ commands:
powershell:
- description: Get application versions
command: Get-ApplicationVersionCollection -Application 1234
skipTest: true

go:
- description: Get application versions
Expand Down Expand Up @@ -58,8 +59,10 @@ commands:
powershell:
- description: Get application version by tag
command: Get-ApplicationVersion -Application 1234 -Tag tag1
skipTest: true
- description: Get application version by version name
command: Get-ApplicationVersion -Application 1234 -Version 1.0
skipTest: true

go:
- description: Get application version by tag
Expand Down Expand Up @@ -157,8 +160,11 @@ commands:
powershell:
- description: Delete application version by tag
command: Remove-ApplicationVersion -Application 1234 -Tag tag1
skipTest: true

- description: Delete application version by version name
command: Remove-ApplicationVersion -Application 1234 -Version 1.0
skipTest: true

go:
- description: Delete application version by tag
Expand Down Expand Up @@ -199,8 +205,11 @@ commands:
powershell:
- description: Get application version by tag
command: Update-ApplicationVersionTag -Application 1234 -Tag tag1
skipTest: true

- description: Get application version by version name
command: Update-ApplicationVersionTag -Application 1234 -Version 1.0
skipTest: true

go:
- description: Replace application version's tags
Expand Down
1 change: 1 addition & 0 deletions api/spec/yaml/notification2Subscriptions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ commands:
powershell:
- description: Delete a subscription associated with a device
command: Remove-Notification2SubscriptionBySource -Device 12345
skipTest: true
go:
- description: Delete a subscription associated with a device
command: c8y notification2 subscriptions deleteBySource --device 12345
Expand Down
1 change: 1 addition & 0 deletions api/spec/yaml/uiPlugins.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ commands:
powershell:
- description: Get ui plugin
command: Get-UIPlugin -Id 1234
skipTest: true

go:
- description: Get ui plugin by id
Expand Down
7 changes: 7 additions & 0 deletions api/spec/yaml/uiPluginsVersions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ commands:
powershell:
- description: Get plugin versions
command: Get-UIPluginVersionCollection -Plugin 1234
skipTest: true

go:
- description: Get plugin versions
Expand Down Expand Up @@ -59,8 +60,10 @@ commands:
powershell:
- description: Get plugin version by tag
command: Get-UIPluginVersion -Plugin 1234 -Tag tag1
skipTest: true
- description: Get plugin version by version name
command: Get-UIPluginVersion -Plugin 1234 -Version 1.0
skipTest: true

go:
- description: Get plugin version by tag
Expand Down Expand Up @@ -160,8 +163,11 @@ commands:
powershell:
- description: Delete plugin version by tag
command: Remove-UIPluginVersion -Plugin 1234 -Tag tag1
skipTest: true

- description: Delete plugin version by version name
command: Remove-UIPluginVersion -Plugin 1234 -Version 1.0
skipTest: true

go:
- description: Delete plugin version by tag
Expand Down Expand Up @@ -210,6 +216,7 @@ commands:
powershell:
- description: Replace tags assigned to a version of a plugin
command: Update-UIPluginVersion -Plugin 1234 -Version 1.0 -Tags tag1,latest
skipTest: true

go:
- description: Replace tags assigned to a version of a plugin
Expand Down
4 changes: 2 additions & 2 deletions tools/PSc8y/Tests/Get-ApplicationVersion.auto.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ Describe -Name "Get-ApplicationVersion" {

}

It "Get application version by tag" {
It -Skip "Get application version by tag" {
$Response = PSc8y\Get-ApplicationVersion -Application 1234 -Tag tag1
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
}

It "Get application version by version name" {
It -Skip "Get application version by version name" {
$Response = PSc8y\Get-ApplicationVersion -Application 1234 -Version 1.0
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Describe -Name "Get-ApplicationVersionCollection" {

}

It "Get application versions" {
It -Skip "Get application versions" {
$Response = PSc8y\Get-ApplicationVersionCollection -Application 1234
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
Expand Down
2 changes: 1 addition & 1 deletion tools/PSc8y/Tests/Get-UIPlugin.auto.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Describe -Name "Get-UIPlugin" {

}

It "Get ui plugin" {
It -Skip "Get ui plugin" {
$Response = PSc8y\Get-UIPlugin -Id 1234
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
Expand Down
4 changes: 2 additions & 2 deletions tools/PSc8y/Tests/Get-UIPluginVersion.auto.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ Describe -Name "Get-UIPluginVersion" {

}

It "Get plugin version by tag" {
It -Skip "Get plugin version by tag" {
$Response = PSc8y\Get-UIPluginVersion -Plugin 1234 -Tag tag1
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
}

It "Get plugin version by version name" {
It -Skip "Get plugin version by version name" {
$Response = PSc8y\Get-UIPluginVersion -Plugin 1234 -Version 1.0
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Describe -Name "Get-UIPluginVersionCollection" {

}

It "Get plugin versions" {
It -Skip "Get plugin versions" {
$Response = PSc8y\Get-UIPluginVersionCollection -Plugin 1234
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
Expand Down
4 changes: 2 additions & 2 deletions tools/PSc8y/Tests/Remove-ApplicationVersion.auto.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ Describe -Name "Remove-ApplicationVersion" {

}

It "Delete application version by tag" {
It -Skip "Delete application version by tag" {
$Response = PSc8y\Remove-ApplicationVersion -Application 1234 -Tag tag1
$LASTEXITCODE | Should -Be 0
}

It "Delete application version by version name" {
It -Skip "Delete application version by version name" {
$Response = PSc8y\Remove-ApplicationVersion -Application 1234 -Version 1.0
$LASTEXITCODE | Should -Be 0
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Describe -Name "Remove-Notification2SubscriptionBySource" {

}

It "Delete a subscription associated with a device" {
It -Skip "Delete a subscription associated with a device" {
$Response = PSc8y\Remove-Notification2SubscriptionBySource -Device 12345
$LASTEXITCODE | Should -Be 0
}
Expand Down
4 changes: 2 additions & 2 deletions tools/PSc8y/Tests/Remove-UIPluginVersion.auto.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ Describe -Name "Remove-UIPluginVersion" {

}

It "Delete plugin version by tag" {
It -Skip "Delete plugin version by tag" {
$Response = PSc8y\Remove-UIPluginVersion -Plugin 1234 -Tag tag1
$LASTEXITCODE | Should -Be 0
}

It "Delete plugin version by version name" {
It -Skip "Delete plugin version by version name" {
$Response = PSc8y\Remove-UIPluginVersion -Plugin 1234 -Version 1.0
$LASTEXITCODE | Should -Be 0
}
Expand Down
4 changes: 2 additions & 2 deletions tools/PSc8y/Tests/Update-ApplicationVersionTag.auto.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ Describe -Name "Update-ApplicationVersionTag" {

}

It "Get application version by tag" {
It -Skip "Get application version by tag" {
$Response = PSc8y\Update-ApplicationVersionTag -Application 1234 -Tag tag1
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
}

It "Get application version by version name" {
It -Skip "Get application version by version name" {
$Response = PSc8y\Update-ApplicationVersionTag -Application 1234 -Version 1.0
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
Expand Down
2 changes: 1 addition & 1 deletion tools/PSc8y/Tests/Update-UIPluginVersion.auto.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Describe -Name "Update-UIPluginVersion" {

}

It "Replace tags assigned to a version of a plugin" {
It -Skip "Replace tags assigned to a version of a plugin" {
$Response = PSc8y\Update-UIPluginVersion -Plugin 1234 -Version 1.0 -Tags tag1,latest
$LASTEXITCODE | Should -Be 0
$Response | Should -Not -BeNullOrEmpty
Expand Down

0 comments on commit abb5d34

Please sign in to comment.