Comment Spacing, Indentation, and Capitalization (#1084)

* Comment Spacing, Indentation, and Capitalization

* Comment Grammar and Spacing

Makes grammar in comments better and more consistent
Adds space before comment and centers word in `Write-Host` commands

* More Grammar and Formatting

* Add some comments

* Populate PlaceHolder comments in functions

Files I found that has issues:
Get-WinUtilRegistry.ps1
Install-WinUtilWinget.ps1
Invoke-WinUtilDarkMode.ps1
Remove-WinUtilAPPX.ps1
Test-WinUtilPackageManager.ps1
Update-WinUtilProgramWinget.ps1

Invoke-WPFUpdatessecurity.ps1

* Tweak a few more comments

* Tweak another write-host statement

* Undo Catch statement adjustment

It's outside of the scope of this pull request
This commit is contained in:
Carter
2023-10-04 10:22:21 -05:00
committed by Carterpersall
parent 932ec6a0a0
commit acc2b5b243
13 changed files with 165 additions and 477 deletions

27
pester/winutil.Tests.ps1 Normal file
View File

@ -0,0 +1,27 @@
# Load Variables needed for testing
./Compile.ps1
$script = Get-Content .\winutil.ps1
# Remove the part of the script that shows the form, leaving only the variable and function declarations
$script[0..($script.count - 21)] | Out-File .\pester.ps1
BeforeAll {
# Execute the truncated script, bringing the variabes into the current scope
. .\pester.ps1
}
Describe "GUI" {
Context "XML" {
It "Imports with no errors" {
$inputXML | should -Not -BeNullOrEmpty
}
}
Context "Form" {
It "Imports with no errors" {
$sync.Form | should -Not -BeNullOrEmpty
}
}
}