GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — Add tests for Dsc configuration compilation on Windows by Indhukrishna · Pull Request #5011 · PowerShell/PowerShell Conversation
Contributor
This PR adds tests for testing Dsc Configuration compilation on Windows. #4570
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
Indhu Sivaramakrishnan (Indhukrishna)
requested a review
from Dongbo Wang (daxian-dbw)
|
There was an error while loading. Please reload this page.
|
for the sake of my OCD, please align the "Ensure" with "Destination Path" and align all three resources at the same column position. :) |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Arie Heinrich (@ArieHein) Thanks for the feedback. I opened it in VSCode and ISE and fixed it. But in the Github UI, I can see that the indentation is still messed up. How do I fix this properly? |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| } | ||
|
|
||
| DSCTestConfig | ||
| "@).Invoke() |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
It might be good to put this in the form of {[Scr...Invoke()}|should not throw and/or verify the expected file gets created.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
I've submitted a PR to your branch to make this change: Indhukrishna#1
I'll make the change directly, once the tests pass if you would like me to.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Tests have passed on Linux and Windows. I'm going to push to your branch.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| } | ||
|
|
||
| DSCTestConfig | ||
| "@).Invoke() |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
same comment
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…o insivara/AddDscCompilationTests/1710
|
|
||
| DSCTestConfig | ||
| "@).Invoke() | ||
| "@).Invoke() | Should Not Throw; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
these tests should fail... a script block should be piped to should not throw
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| "@).Invoke() | ||
| "@).Invoke() | ||
|
|
||
| Test-Path -Path .\DSCTestConfig\localhost.mof | Should Be $True |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
to verify a file exists, please use `` | should exist` , it results it better errors
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Updated
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
|
||
| ".\DSCTestConfig\localhost.mof" | Should Exist | ||
|
|
||
| Remove-Item -Force -Recurse -Path DSCTestConfig |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
The remove should be in an AfterEach or the finally or a try{}finally{} otherwise it won't run if the test fails. Might be easier to just use the test drive...
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
I've submitted a PR to resolve this: Indhukrishna#2 . I'll merge it if the tests pass.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.