You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Details of the scenario you tried and the problem that is occurring
There's a number of script analyzer issues getting reported in MSFT_xEnvironmentResource.psm1. These should be fixed.
Verbose logs showing the problem
[00:03:51] Context MSFT_xEnvironmentResource.psm1
[00:03:51] [+] Should pass all error-level PS Script Analyzer rules 89ms
[00:03:54] [+] Should pass all required PS Script Analyzer rules 2.94s
[00:03:55] [+] Should pass all flagged PS Script Analyzer rules 684ms
[00:03:55] [+] Should pass any recently-added, error-level PS Script Analyzer rules 73ms
[00:03:57] [+] Should not suppress any required PS Script Analyzer rules 1.73s
[00:03:57] Custom DSC Resource Kit PSSA rule(s) did not pass.
[00:03:57] The following PSScriptAnalyzer rule 'DscResource.AnalyzerRules\Measure-ForEachStatement' errors need to be fixed:
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 696): Opening brace on foreach-statements should be followed by a new line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 1025): Opening brace on foreach-statements should be followed by a new line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace
[00:03:57] The following PSScriptAnalyzer rule 'DscResource.AnalyzerRules\Measure-IfStatement' errors need to be fixed:
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 49): Opening brace on if-statements should be followed by a new line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 69): Opening brace on if-statements should be followed by a new line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 193): Opening brace on if-statements should only be followed by one new line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 527): Opening brace on if-statements should be followed by a new line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 529): Opening brace on if-statements should be followed by a new line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace
[00:03:57] The following PSScriptAnalyzer rule 'DscResource.AnalyzerRules\Measure-ParameterBlockParameterAttribute' errors need to be fixed:
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 41): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 125): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 129): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 133): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 136): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 433): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 437): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 441): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 444): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 806): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] MSFT_xEnvironmentResource.psm1 (Line 934): A [Parameter()] attribute must be the first attribute of each parameter and be on its own line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#correct-format-for-parameter-block
[00:03:57] For instructions on how to run PSScriptAnalyzer on your own machine, please go to https://github.com/powershell/PSScriptAnalyzer
[00:03:57] Common Tests - Custom Script Analyzer Rules will not fail unless you opt-in.
[00:03:57] To opt-in, create a '.MetaTestOptIn.json' at the root
[00:03:57] of the repo in the following format:
[00:03:57] [
[00:03:57] "Common Tests - Custom Script Analyzer Rules"
[00:03:57] ]
[00:03:57] [+] Should pass all custom DSC Resource Kit PSSA rules 874ms
Version of the DSC module that was used ('dev' if using current dev branch)
dev
The text was updated successfully, but these errors were encountered:
Details of the scenario you tried and the problem that is occurring
There's a number of script analyzer issues getting reported in MSFT_xEnvironmentResource.psm1. These should be fixed.
Verbose logs showing the problem
Version of the DSC module that was used ('dev' if using current dev branch)
dev
The text was updated successfully, but these errors were encountered: