-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Get|Set-ArubaSWPort #40
Conversation
Information like name/description, Configuration Mode (Speed..), status...
name/description, Mode Configuration, status...
@CedricMoreau can you look ? |
PowerArubaSW/Public/Port.ps1
Outdated
Get Port of the Switch | ||
|
||
.DESCRIPTION | ||
Get Portinformation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a space ? (Between port and informtion)
PowerArubaSW/Public/Port.ps1
Outdated
|
||
<# | ||
.SYNOPSIS | ||
Get Port Sstatisticsof the Switch |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a space
PowerArubaSW/Public/Port.ps1
Outdated
Get Port Sstatisticsof the Switch | ||
|
||
.DESCRIPTION | ||
Get Portinformation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a space
} else { | ||
$_port | add-member -name "is_dsnoop_port_trusted" -membertype NoteProperty -Value $false | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a blank line maybe ?
} | ||
$response = invoke-ArubaSWWebRequest -method "PUT" -body $_port -url $url | ||
|
||
$response | convertfrom-json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a blank line too
Set-ArubaSWPort -port_id 3 -name DEFAULT_PORT | ||
#Always enable the port (disabled on WorkBench...) | ||
Set-ArubaSWPort -port_id 3 -is_port_enable | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a blank line ?
Tests/integration/Port.Tests.ps1
Outdated
} | ||
|
||
It "Get ALL Port" { | ||
$PORTS = Get-ArubaSWPort |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indent ? (not the same as below )
#TODO: Add check if no ipaddress/login/password info... | ||
|
||
Describe "Get Port" { | ||
BeforeAll { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a blank line (or remove it at line 43)
$PORT.drop_tx | Should -Not -BeNullOrEmpty | ||
$PORT.port_speed_mbps | Should -Not -BeNullOrEmpty | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a blank line ?
Tests/integration/Port.Tests.ps1
Outdated
} | ||
|
||
It "Get ALL Port Stastistics" { | ||
$PORTS = Get-ArubaSWPortStatistics |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indent ?
2 new Get (Get-ArubaSWPort/Get-ArubaSWPortStatistics) and a Set (Set-ArubaSWPort) cmdlets
3 new cmdlets * Enhance speed (Don't wait 5sec between each request...) (PowerAruba#32) * Enhance security (Enable TLS 1.2 when HTTPS is used...) (PowerAruba#60) * Better "error" message when fail to connect or use a API (PowerAruba#55) * Add -usebasicparsing for use without connnected session (like task) (PowerAruba#56) * Add integration test (using Pester) for check code (Known issue about VSF Switch) (PowerAruba#36) * Add Get|Set-ArubaSWPort(-statistics) to get and configure a port (name, status, mode...) and Port statistics (name, packets/bytes/throughtput/error TX or RX...) (PowerAruba#40) * Add [Extract-Port-ArubaSW.ps1 tools script](https://github.com/PowerAruba/PowerArubaSW/blob/master/Tools/Extract-Port-ArubaSW.ps1) for generate a Excel file with the list of Port and configuration (vlan, status, lldp neighbor...) (PowerAruba#34) * 4 removed cmdlets (Get-ArubaSWSystemStatus[Cpu|Memory|Storage|Time] (PowerAruba#43)
3 new cmdlets * Enhance speed (Don't wait 5sec between each request...) (PowerAruba#32) * Enhance security (Enable TLS 1.2 when HTTPS is used...) (PowerAruba#60) * Better "error" message when fail to connect or use a API (PowerAruba#55) * Add -usebasicparsing for use without connnected session (like task) (PowerAruba#56) * Add integration test (using Pester) for check code (Known issue about VSF Switch) (PowerAruba#36) * Add Get|Set-ArubaSWPort(-statistics) to get and configure a port (name, status, mode...) and Port statistics (name, packets/bytes/throughtput/error TX or RX...) (PowerAruba#40) * Add [Extract-Port-ArubaSW.ps1 tools script](https://github.com/PowerAruba/PowerArubaSW/blob/master/Tools/Extract-Port-ArubaSW.ps1) for generate a Excel file with the list of Port and configuration (vlan, status, lldp neighbor...) (PowerAruba#34) * 4 removed cmdlets (Get-ArubaSWSystemStatus[Cpu|Memory|Storage|Time] (PowerAruba#43)
3 new cmdlets * Enhance speed (Don't wait 5sec between each request...) (#32) * Enhance security (Enable TLS 1.2 when HTTPS is used...) (#60) * Better "error" message when fail to connect or use a API (#55) * Add -usebasicparsing for use without connnected session (like task) (#56) * Add integration test (using Pester) for check code (Known issue about VSF Switch) (#36) * Add Get|Set-ArubaSWPort(-statistics) to get and configure a port (name, status, mode...) and Port statistics (name, packets/bytes/throughtput/error TX or RX...) (#40) * Add [Extract-Port-ArubaSW.ps1 tools script](https://github.com/PowerAruba/PowerArubaSW/blob/master/Tools/Extract-Port-ArubaSW.ps1) for generate a Excel file with the list of Port and configuration (vlan, status, lldp neighbor...) (#34) * 4 removed cmdlets (Get-ArubaSWSystemStatus[Cpu|Memory|Storage|Time] (#43)
Add cmdlets for Get and Configure Port (name, config, status, flow control, dsnoop trust...)