Skip to content

Commit a24b171

Browse files
author
François Chabot
committed
Refactor nested modules as dotsourced scripts
fix comments fix ipmo path Fix tests code layout
1 parent 25c3f5b commit a24b171

17 files changed

+33
-39
lines changed
File renamed without changes.

Alias/Tests/Get-CommandAlias.Tests.ps1

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,10 @@
1616

1717
#endregion
1818

19-
Import-Module -Name $PSScriptRoot\..\Alias -Force
20-
Import-Module -Name $PSScriptRoot\..\..\ActionPreference -Force
19+
Import-Module -Name $PSScriptRoot\..\..\Psx.psm1 -Force
2120

2221
Describe 'Get-CommandAlias' {
23-
InModuleScope Alias {
22+
InModuleScope Psx {
2423

2524
Context 'When commands and aliases exist' {
2625
It 'Returns itself and aka alias.' {

HashTable/Tests/Bug-HashTable.Tests.ps1

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@
1616

1717
#endregion
1818

19-
Import-Module -Name $PSScriptRoot\..\HashTable -Force
20-
Import-Module -Name $PSScriptRoot\..\..\ActionPreference -Force
19+
Import-Module -Name $PSScriptRoot\..\..\Psx.psm1 -Force
2120

2221
Describe 'Bug related to HashTable that appeared with PowerShell 7.0' {
2322
It 'Throws an exception due a bug present in PowerShell 7.0 related to HashTable.' {

HashTable/Tests/Compare-Hashtable.Tests.ps1

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,10 @@
1616

1717
#endregion
1818

19-
Import-Module -Name $PSScriptRoot\..\HashTable -Force
20-
Import-Module -Name $PSScriptRoot\..\..\ActionPreference -Force
19+
Import-Module -Name $PSScriptRoot\..\..\Psx.psm1 -Force
2120

2221
Describe 'Compare-Hashtable' {
23-
InModuleScope HashTable {
22+
InModuleScope Psx {
2423

2524
Context 'When both are empty' {
2625
It 'Returns nothing.' {
@@ -65,7 +64,7 @@ Describe 'Compare-Hashtable' {
6564
}
6665

6766
Context 'When both contain various stuff' {
68-
BeforeAll{
67+
BeforeAll {
6968
$left = @{ a = 1 ; b = 2 ; c = 3 ; f = $null ; g = 6 ; k = $null }
7069
$right = @{ b = 2 ; c = 4 ; e = 5 ; f = $null ; g = $null ; k = 7 }
7170
$results = Compare-HashTable $left $right

HashTable/Tests/Merge-HashTable.Tests.ps1

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,10 @@
1616

1717
#endregion
1818

19-
Import-Module -Name $PSScriptRoot\..\HashTable -Force
20-
Import-Module -Name $PSScriptRoot\..\..\ActionPreference -Force
19+
Import-Module -Name $PSScriptRoot\..\..\Psx.psm1 -Force
2120

2221
Describe 'Merge-HashTable' {
23-
InModuleScope HashTable {
22+
InModuleScope Psx {
2423

2524
Context 'When HashTables are given by arguments' {
2625
It 'Merges HashTables.' {
File renamed without changes.

0 commit comments

Comments
 (0)