Fix test failures in win_command/win_shell on Powershell 3

Switched to use Exit-Json to avoid JSON escaping bugs in ConvertTo-Json formatter without -Compress option.
This commit is contained in:
Matt Davis 2016-11-29 14:19:51 -08:00 committed by Matt Clay
parent 61060f4b5f
commit ce0412aa85
2 changed files with 2 additions and 2 deletions

View file

@ -158,4 +158,4 @@ $result.start = $start_datetime.ToString("yyyy-MM-dd hh:mm:ss.ffffff")
$result.end = $end_datetime.ToString("yyyy-MM-dd hh:mm:ss.ffffff")
$result.delta = $($end_datetime - $start_datetime).ToString("h\:mm\:ss\.ffffff")
ConvertTo-Json -Depth 99 $result
Exit-Json $result

View file

@ -139,4 +139,4 @@ $result.start = $start_datetime.ToString("yyyy-MM-dd hh:mm:ss.ffffff")
$result.end = $end_datetime.ToString("yyyy-MM-dd hh:mm:ss.ffffff")
$result.delta = $($end_datetime - $start_datetime).ToString("h\:mm\:ss\.ffffff")
ConvertTo-Json -Depth 99 $result
Exit-Json $result