@@ -118,7 +118,7 @@ Describe PowerShell.PSGet.UpdateModuleManifest -Tags 'BVT','InnerLoop' {
118
118
# Action:
119
119
# Update-ModuleManifest -Path [Path]
120
120
#
121
- # Expected Result: The updated manifest should have the same proerty values.
121
+ # Expected Result: The updated manifest should have the same property values.
122
122
#
123
123
It UpdateModuleManifestWithNoAdditionalParameters2 {
124
124
@@ -144,6 +144,29 @@ Describe PowerShell.PSGet.UpdateModuleManifest -Tags 'BVT','InnerLoop' {
144
144
145
145
AssertEquals $updatedModuleInfo.CompanyName $editedModuleInfo.CompanyName " Company name should be $expectedCompanyName "
146
146
AssertEquals $ ($text.length ) $expectedLength " Number of wildcards should be $expectedLength "
147
+ }
148
+
149
+ # Purpose: Validate Update-ModuleManifest will not reset original parameter values to default values
150
+ #
151
+ # Action:
152
+ # Update-ModuleManifest -Path [Path]
153
+ #
154
+ # Expected Result: The updated manifest should have the same property values.
155
+ #
156
+ It UpdateModuleManifestWithNoAdditionalParameters3 {
157
+
158
+ New-ModuleManifest - Path $script :testManifestPath - ModuleVersion ' 1.0' - FunctionsToExport ' function1' - NestedModules ' Microsoft.PowerShell.Management' - AliasesToExport ' alias1'
159
+ Update-ModuleManifest - Path $script :testManifestPath
160
+
161
+ Import-LocalizedData - BindingVariable ModuleManifestHashTable `
162
+ - FileName (Microsoft.PowerShell.Management\Split-Path $script :testManifestPath - Leaf) `
163
+ - BaseDirectory (Microsoft.PowerShell.Management\Split-Path $script :testManifestPath - Parent) `
164
+ - ErrorAction SilentlyContinue `
165
+ - WarningAction SilentlyContinue
166
+
167
+ AssertEquals $ModuleManifestHashTable.FunctionsToExport ' function1' " FunctionsToExport should be 'function1'"
168
+ AssertEquals $ModuleManifestHashTable.NestedModules ' Microsoft.PowerShell.Management' " NestedModules should be 'module1'"
169
+ AssertEquals $ModuleManifestHashTable.AliasesToExport ' alias1' " AliasesToExport should be 'alias1'"
147
170
}
148
171
149
172
# Purpose: Validate Update-ModuleManifest will keep the original property values for DefaultCommandPrefix,
@@ -214,7 +237,6 @@ Describe PowerShell.PSGet.UpdateModuleManifest -Tags 'BVT','InnerLoop' {
214
237
AssertEquals $updatedModuleInfo.AliasesToExport.Count 0 " AliasesToExport count should be 0"
215
238
}
216
239
217
-
218
240
# Purpose: Update a module manifest with same parameters
219
241
#
220
242
# Action: Update-ModuleManifest -Path [path] -NestedModules -Guid -Author -CompanyName -Copyright -RootModule -ModuleVersion...
@@ -652,7 +674,6 @@ Describe PowerShell.PSGet.UpdateModuleManifest -Tags 'BVT','InnerLoop' {
652
674
653
675
}
654
676
655
-
656
677
# Purpose: Validate Update-ModuleManifest will throw errors when there are paths defined in FilePath that are not in the module base
657
678
#
658
679
# Action:
0 commit comments