win_psDscAdapter and psDscAdapter PScredentials fix for passing username and password#1308
Conversation
…nvert to System.Management.Automation.PSCredentia
|
@microsoft-github-policy-service agree
@microsoft-github-policy-service agree |
|
@mimachniak - as I have already spoken with you on socials, is this perhaps also possible for class-based DSC resources (both in the 5.1 and 7.0 adapter)? Can you also include a testcase that covers this change? |
|
Yes I working o it |
…rt to System.Management.Automation.PSCredentia - code optimalization remove unused function
…tem.Management.Automation.PSCredential
…t to System.Management.Automation.PSCredential
…t to System.Management.Automation.PSCredential - if change to recognize user information
|
@Gijsreyn , @SteveL-MSFT - I added in test folder yaml's that are using TestClass for validation using PSCredentials, I tested on version 5.1 and 7 of PowerShell |
|
@mimachniak - can it be tested inside the |
I will add today, I added yaml files for running test |
…alid secure object
I added unit test and validation in file in powershellgroup.config.tests.ps1 |
|
I added test for 5.1 as well |
|
@mimachniak Thanks for adding the test resource, but there isn't a Pester test using it yet? |
|
@SteveL-MSFT I will add test today |
…sc for script resources
… parameters - credentials
…ameters - credentials
Test added and minor fix to adapter as well |
|
@SteveL-MSFT I see that I need to add to test in script base module creation, I will do it today |
|
@mimachniak Some Windows Pester tests failed in CI, can you take a look at those? Also look over the Copilot feedback and see if any should be addressed. Thanks! |
Yes I'm fixing this as well |
|
@SteveL-MSFT - fix all co-pilot subjects, and added unit test for script base resources |
Can you allow to run checks ? |
Need one more time, I have mispel in test file |
|
@SteveL-MSFT please run job for test I think this time all test should be ok |
Can you run check |
|
@SteveL-MSFT build was failing on some clippy I update branch, can you allow to run check. |
|
@SteveL-MSFT don't know why this got error, rest looks ok - some fix in class base test is added BUILD: Cleaning up
BUILD: Cleaning up::Restoring rust environment
VERBOSE: Resetting Rust environment...
VERBOSE: No Rust environment variables defined
VERBOSE: Reset rust environment
VERBOSE: No Rust environment variables defined
Finished build script
Write-Error: D:\a\_temp\e59c5db3-f145-4208-a7bd-5c0daaf21951.ps1:8
Line |
8 | ./build.ps1 @params -PesterTestGroup extensions
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| An error occurred: Install-PSResource: 'Response status code does not indicate success: 999.' Request sent:
| 'https://www.powershellgallery.com/api/v2/FindPackagesById()?$filter=Id+eq+%27PSDesiredStateConfiguration%27+and+Normali zedVersion+eq+%272.0.7%27&$inlinecount=allpages&id=%27PSDesiredStateConfiguration%27'
Error: Process completed with exit code 1.
|
PR Summary
PR Context
Fix using ScriptBased DSC resources when is reguired to use parameters with Get-Credentials