Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/dotnet-core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 2.1.402
dotnet-version: 5.0.100

- name: Build
env:
FSHARP_DATA_SQLCLIENT_USE_SQLLOCALDB_FOR_TESTS: 1
run: |
call "C:\Program Files\Microsoft SQL Server\130\Tools\Binn\SqlLocalDB.exe" info
./build.cmd
SqlLocalDB.exe info
./build.cmd
2 changes: 1 addition & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
init:
- git config --global core.autocrlf input
image: Visual Studio 2017
image: Visual Studio 2019
build_script:
- cmd: build.cmd GenerateDocs
test: off
Expand Down
41 changes: 33 additions & 8 deletions build.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,35 @@ let slnPath = "SqlClient.sln"
let testProjectsSlnPath = "TestProjects.sln"
let testSlnPath = "Tests.sln"
let testProjectPath = "tests/SqlClient.Tests/SqlClient.Tests.fsproj"
let runMsBuild project =
Fake.DotNet.MSBuild.build
(fun args ->
let toolPath =
[
@"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin"
@"C:\Program Files (x86)\Microsoft Visual Studio\2019\Preview\MSBuild\current\Bin"
@"C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\MSBuild\current\Bin"
@"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\current\Bin"
@"C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin"
@"C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\15.0\Bin"
@"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin"
@"C:\Program Files (x86)\MSBuild\15.0\Bin"
@"\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin"
args.ToolPath
]
|> List.map (fun p -> Path.Combine(p, "MSBuild.exe"))
|> List.find File.Exists
let properties =
[ yield "Configuration", "Release"
for n,v in args.Properties do
if n <> "Configuration" then
yield n,v
]
{ args
with ToolPath = toolPath
Properties = properties
} ) project


Target.create "Clean" (fun _ ->
Shell.cleanDirs ["bin"; "temp"]
Expand Down Expand Up @@ -165,21 +194,17 @@ Target.create "DeployTestDB" (fun _ ->
)

Target.create "BuildTestProjects" (fun _ ->
DotNet.build
(fun args ->
{
args with
Configuration = DotNet.Release
//Common = { args.Common with Verbosity = Some DotNet.Verbosity.Detailed }
} |> dnDefault)
testProjectsSlnPath
DotNet.restore dnDefault testProjectsSlnPath
runMsBuild testProjectsSlnPath
)

// --------------------------------------------------------------------------------------
// Run the unit tests
Target.create "RunTests" (fun _ ->
// if we don't compile the targets sequentially, we get an error with the generated types:
// System.IO.IOException: The process cannot access the file 'C:\Users\foo\AppData\Local\Temp\tmpF38.dll' because it is being used by another process.
DotNet.restore dnDefault testSlnPath
runMsBuild testSlnPath
try
DotNet.test (fun args -> { args with Framework = Some "net461"; Common = args.Common |> dnDefault }) testSlnPath
DotNet.test (fun args -> { args with Framework = Some "netcoreapp2.0"; Common = args.Common |> dnDefault }) testProjectPath
Expand Down
6 changes: 5 additions & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
{ "sdk": { "version": "2.1.402" } }
{
"sdk": {
"version": "5.0.100"
}
}
29 changes: 18 additions & 11 deletions paket.dependencies
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
source https://www.nuget.org/api/v2/
generate_load_scripts: on

storage: none
github fsprojects/FSharp.TypeProviders.SDK:28a24a69ada68ebd1ad25226634f4608e4875493 src/ProvidedTypes.fs
github fsprojects/FSharp.TypeProviders.SDK:28a24a69ada68ebd1ad25226634f4608e4875493 src/ProvidedTypes.fsi
github fsprojects/FSharp.TypeProviders.SDK:28a24a69ada68ebd1ad25226634f4608e4875493 src/ProvidedTypesTesting.fs
Expand All @@ -9,7 +9,7 @@ group Build
source https://www.nuget.org/api/v2/
framework: >= net451
generate_load_scripts: on

nuget FAKE = 5.8.4
nuget Fake.Lib = 5.8.4

Expand All @@ -21,8 +21,9 @@ group Build

group DesignTime
source https://www.nuget.org/api/v2/
framework: >= net461,netstandard20

framework: >= net461, >= netstandard20
storage: none

nuget System.Configuration.ConfigurationManager
nuget System.Data.Common
nuget System.Data.SqlClient
Expand All @@ -33,9 +34,10 @@ group DesignTime

group Test
source https://www.nuget.org/api/v2/
framework: net461, netcoreapp2.0
framework: >= net461, >= netcoreapp2.0
storage: none

nuget FSharp.Core = 4.5.2 redirects:force
nuget FSharp.Core = 5.0.0 redirects:force
nuget System.Data.SqlClient
nuget System.Configuration.ConfigurationManager

Expand All @@ -47,12 +49,14 @@ group Test
group Net40
source https://www.nuget.org/api/v2/
framework: net40
storage: none

nuget FSharp.Core = 4.1.18

group TestProjects
source https://www.nuget.org/api/v2/
framework: >= net40, netcoreapp2.0, netstandard2.0
framework: >= net40, >= netcoreapp2.0, >= netstandard2.0
storage: none

nuget FSharp.Core = 4.3.4

Expand All @@ -61,14 +65,17 @@ group TestProjects

group Samples
source https://www.nuget.org/api/v2/
framework: >= net40

nuget FSharp.Core = 4.5.2
framework: >= net40, >= netcoreapp2.0, >= netstandard2.0
redirects: on

nuget FSharp.Core = 4.5.2 redirects: force

nuget Microsoft.AspNet.WebApi
nuget Microsoft.AspNet.WebApi.Client
nuget Microsoft.AspNet.WebApi.Core
nuget Microsoft.AspNet.WebApi.WebHost
nuget Microsoft.SqlServer.Types

nuget Newtonsoft.Json
nuget Newtonsoft.Json redirects: force
nuget FSharp.Data.SqlClient

Loading