mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-10-22 20:13:59 -07:00
Add pslint sanity test. (#35303)
* Add pslint sanity test. * Fix `no-smart-quotes` sanity test. * Add docs for `pslint` sanity test.
This commit is contained in:
parent
7c201fc9bc
commit
e0010f15e4
7 changed files with 391 additions and 1 deletions
14
test/sanity/pslint/pslint.ps1
Executable file
14
test/sanity/pslint/pslint.ps1
Executable file
|
@ -0,0 +1,14 @@
|
|||
#!/usr/bin/env pwsh
|
||||
#Requires -Version 6
|
||||
#Requires -Modules PSScriptAnalyzer
|
||||
|
||||
Set-StrictMode -Version 2.0
|
||||
$ErrorActionPreference = "Stop"
|
||||
|
||||
$Results = @()
|
||||
|
||||
ForEach ($Path in $Args) {
|
||||
$Results += Invoke-ScriptAnalyzer -Path $Path
|
||||
}
|
||||
|
||||
ConvertTo-Json -InputObject $Results
|
Loading…
Add table
Add a link
Reference in a new issue