-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathtest.ps1
More file actions
30 lines (24 loc) · 1.13 KB
/
Copy pathtest.ps1
File metadata and controls
30 lines (24 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
Set-StrictMode -Version 3.0
$ErrorActionPreference = "Stop"
$PSNativeCommandUserErrorActionPerference = $true
# get the location of this file
$scriptpath = $MyInvocation.MyCommand.Path
# get the directory path to this file
$wd = Split-Path $scriptpath
# set the working directory as this file's directory
Push-Location $wd
# create dlls/run_tests.hxx so that test.h enables test code
New-Item -Path "dlls" -Name "run_tests.hxx" -ItemType "file" -Force
MSBuild.exe /t:Build /p:Platform=x86 /p:Configuration=Release "sandbot.sln"
MSBuild.exe /t:Build /p:Platform=x64 /p:Configuration=Release "sandbot.sln"
# remove dlls/run_tests.hxx so that subsequent work doesn't get messed up by its presence
Remove-Item dlls\run_tests.hxx
Write-Output "--------------------------------"
Write-Output "Running x86 tests"
Write-Output "--------------------------------"
vstest.console.exe Release\sandbot.dll --logger:"console;verbosity=Normal"
Write-Output "--------------------------------"
Write-Output "Running x64 tests"
Write-Output "--------------------------------"
vstest.console.exe x64\Release\sandbot.dll --logger:"console;verbosity=Normal"
Pop-Location