Skip to content

Commit

Permalink
Merge pull request #3728 from menswearUK/#3727
Browse files Browse the repository at this point in the history
#3727 - TestHarness.psm1 -DscTestsPath  parameter
  • Loading branch information
NikCharlebois authored Oct 3, 2023
2 parents 095fe8f + 2d36598 commit c892f05
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
* Initial release.
* DEPENDENCIES
* Updated MSCloudLoginAssistant to version 1.0.121.
* TestHarness.psm1
* Added code around DscTestsPath parameter to target a single test file during development

# 1.23.927.1

Expand Down
15 changes: 11 additions & 4 deletions Tests/TestHarness.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,17 @@ function Invoke-TestHarness
$testsToRun += @( $commonTestFiles.FullName )

$filesToExecute = @()
foreach ($testToRun in $testsToRun)
{
$filesToExecute += $testToRun
}
if ($DscTestsPath -ne "")
{
$filesToExecute += $DscTestsPath
}
else
{
foreach ($testToRun in $testsToRun)
{
$filesToExecute += $testToRun
}
}

$Params = [ordered]@{
Path = $filesToExecute
Expand Down

0 comments on commit c892f05

Please sign in to comment.