Skip to content

Commit

Permalink
Add tests for CliBatch Function
Browse files Browse the repository at this point in the history
  • Loading branch information
Cédric Moreau committed Feb 25, 2019
1 parent 10d5055 commit 1bd9da5
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions Tests/integration/CliBatch.Tests.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#
# Copyright 2019, Alexis La Goutte <alexis.lagoutte at gmail dot com>
# Copyright 2019, Cédric Moreau <moreaucedric0 at gmail dot com>
#
# SPDX-License-Identifier: Apache-2.0
#

. ../common.ps1

Describe "Get-ArubaSWCliBatchStatus" {
It "Get ArubaSWCliBatchStatus Does not throw an error" {
{
Get-ArubaSWCliBatchStatus
} | Should Not Throw
}

It "Get ArubaSWCliBatchStatus" {
$cli = Get-ArubaSWCliBatchStatus
$cli | Should not be $NULL
}
}

Describe "Write ArubaSWCliBatch" {
It "Write ArubaSWCliBatch" {
Write-ArubaSWCliBatch -command "interface 4","disable"
$cli = Get-ArubaSWCliBatchStatus
$cli.status | Should be "CCS_SUCCESS"
Write-ArubaSWCliBatch -command "interface 4","enable"
}
}

Disconnect-ArubaSW -noconfirm

0 comments on commit 1bd9da5

Please sign in to comment.