Skip to content

Commit

Permalink
Revert "simplify build.fsx tests"
Browse files Browse the repository at this point in the history
This reverts commit 631a2e1.
  • Loading branch information
AnthonyLloyd committed May 8, 2018
1 parent 631a2e1 commit 9e3fc59
Showing 1 changed file with 12 additions and 16 deletions.
28 changes: 12 additions & 16 deletions build.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,27 +77,23 @@ Target "BuildBenchmarkDotNet" (fun _ ->
build "Expecto.BenchmarkDotNet/Expecto.BenchmarkDotNet.fsproj"
)

let testProjects = [
"Expecto.Tests/Expecto.Tests.fsproj"
"Expecto.Hopac.Tests/Expecto.Hopac.Tests.fsproj"
"Expecto.Tests.CSharp/Expecto.Tests.CSharp.csproj"
"Expecto.Focused.Tests/Expecto.Focused.Tests.fsproj"
]

Target "BuildTest" (fun _ ->
List.iter build testProjects
build "Expecto.Tests/Expecto.Tests.fsproj"
build "Expecto.Hopac.Tests/Expecto.Hopac.Tests.fsproj"
build "Expecto.Tests.CSharp/Expecto.Tests.CSharp.csproj"
build "Expecto.Focused.Tests/Expecto.Focused.Tests.fsproj"
)

Target "RunTest" (fun _ ->
let runTest project =
["netcoreapp2.0"; "net461"]
|> List.iter (fun fwk ->
"run -p ./" + project + " -f " + fwk + " -c " + configuration +
" --no-restore --no-build --summary"
|> DotNetCli.RunCommand (fun p ->
{ p with ToolPath = dotnetExePath })
)
List.iter runTest testProjects
DotNetCli.RunCommand (fun p -> { p with ToolPath = dotnetExePath })
(project+"/bin/"+configuration+"/netcoreapp2.0/"+project+".dll --summary")
Shell.Exec (project+"/bin/"+configuration+"/net461/"+project+".exe","--summary")
|> fun r -> if r<>0 then project+".exe failed" |> failwith
runTest "Expecto.Tests"
runTest "Expecto.Hopac.Tests"
runTest "Expecto.Tests.CSharp"
runTest "Expecto.Focused.Tests"
)

Target "Pack" (fun _ ->
Expand Down

0 comments on commit 9e3fc59

Please sign in to comment.