Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
$Tests = @(
"Running partition tests on : ForestDnsZones"
"Running enterprise tests on : domain.surlyadmin.com"
)
ForEach ($Line in $Tests)
{
Switch ($_) -Regex
{
"running (?<Zone>partition|enterprise) tests on : (?<PartTest>.*)" {
"Test type is: $($Matches.Zone)"
"Test is running in: $($Matches.PartTest"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment