File tree Expand file tree Collapse file tree 1 file changed +7
-9
lines changed
scripts/tests/Module/PSModule Expand file tree Collapse file tree 1 file changed +7
-9
lines changed Original file line number Diff line number Diff line change 88 [string ] $Path
99)
1010
11+ BeforeAll {
12+ $moduleName = Split-Path - Path (Split-Path - Path $Path - Parent) - Leaf
13+ $moduleManifestPath = Join-Path - Path $Path - ChildPath " $moduleName .psd1"
14+ Write-Verbose " Module Manifest Path: [$moduleManifestPath ]"
15+ }
16+
1117Describe ' PSModule - Module tests' {
1218 Context ' Module' {
1319 It ' The module should be importable' {
14- {
15- $moduleName = Split-Path - Path $Path - Leaf
16- Import-Module - Name $moduleName
17- } | Should -Not - Throw
20+ { Import-Module - Name $moduleName } | Should -Not - Throw
1821 }
1922 }
2023
2124 Context ' Module Manifest' {
22- BeforeAll {
23- $moduleName = Split-Path - Path $Path - Leaf
24- $moduleManifestPath = Join-Path - Path $Path - ChildPath " $moduleName .psd1"
25- Write-Verbose " Module Manifest Path: [$moduleManifestPath ]"
26- }
2725 It ' Module Manifest exists' {
2826 $result = Test-Path - Path $moduleManifestPath
2927 $result | Should - Be $true
You can’t perform that action at this time.
0 commit comments