Skip to content

Commit 9e90b2e

Browse files
Add tests for Get-NetIPConfiguration function and implement IPConfig alias
1 parent f945363 commit 9e90b2e

3 files changed

Lines changed: 16 additions & 21 deletions

File tree

src/functions/public/Get-NetIPConfiguration.ps1

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
https://psmodule.io/Net/Functions/Get-NetIPConfiguration
3838
#>
3939

40+
[Alias('IPConfig')]
4041
[CmdletBinding()]
4142
param(
4243
# Filters interfaces based on operational status ('Up' or 'Down')

src/functions/public/Test-PSModuleTest.ps1

Lines changed: 0 additions & 18 deletions
This file was deleted.
Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,20 @@
1919
[CmdletBinding()]
2020
param()
2121

22-
Describe 'Module' {
23-
It 'Function: Test-PSModuleTest' {
24-
Test-PSModuleTest -Name 'World' | Should -Be 'Hello, World!'
22+
Describe 'Net' {
23+
Context 'Get-NetIPConfiguration' {
24+
It 'returns expected results' {
25+
$results = Get-NetIPConfiguration
26+
LogGroup "Results" {
27+
Write-Host "$($results | Format-List | Out-String)"
28+
}
29+
}
30+
31+
It 'IPConfig alias works' {
32+
$results = IPConfig
33+
LogGroup "Results" {
34+
Write-Host "$($results | Format-List | Out-String)"
35+
}
36+
}
2537
}
2638
}

0 commit comments

Comments
 (0)