diff --git a/paket.dependencies b/paket.dependencies index 9afb8e55..4b7b321a 100644 --- a/paket.dependencies +++ b/paket.dependencies @@ -1,6 +1,5 @@ source https://api.nuget.org/v3/index.json - storage: none lowest_matching: true strategy: min @@ -8,10 +7,9 @@ nuget FSharp.Core >= 6.0.1 nuget Hopac >= 0.5.1 nuget FSharp.Control.AsyncSeq >= 3.2.1 nuget Fable.Core >= 4.2.0 -nuget IcedTasks >= 0.10.2 +nuget IcedTasks >= 0.11.0 nuget Microsoft.SourceLink.GitHub prerelease copy_local: true - - +nuget Microsoft.Bcl.AsyncInterfaces >= 6.0.0 framework:netstandard2.0 group Test source https://api.nuget.org/v3/index.json @@ -27,6 +25,7 @@ nuget Fable.Core nuget Fable.Mocha nuget Fable.Python nuget Fable.Pyxpecto +nuget Microsoft.Bcl.AsyncInterfaces >= 6.0.0 group Benchmarks source https://api.nuget.org/v3/index.json diff --git a/paket.lock b/paket.lock index b5222558..8c77b3f8 100644 --- a/paket.lock +++ b/paket.lock @@ -10,17 +10,18 @@ NUGET FSharp.Core (6.0.1) Hopac (0.5.1) FSharp.Core (>= 4.5.2) - restriction: >= netstandard2.0 - IcedTasks (0.10.2) + IcedTasks (0.11) FSharp.Core (>= 6.0.1) - restriction: >= netstandard2.0 - Microsoft.Bcl.AsyncInterfaces (5.0) - restriction: >= netstandard2.0 - System.Threading.Tasks.Extensions (>= 4.5.4) - restriction: || (>= net461) (&& (< netcoreapp2.1) (>= netstandard2.0) (< netstandard2.1)) + Microsoft.Bcl.AsyncInterfaces (>= 6.0) - restriction: && (>= netstandard2.0) (< netstandard2.1) + Microsoft.Bcl.AsyncInterfaces (6.0) - restriction: == netstandard2.0 + System.Threading.Tasks.Extensions (>= 4.5.4) - restriction: || (>= net461) (&& (>= netstandard2.0) (< netstandard2.1)) Microsoft.Build.Tasks.Git (8.0) - copy_local: true Microsoft.SourceLink.Common (8.0) - copy_local: true Microsoft.SourceLink.GitHub (8.0) - copy_local: true Microsoft.Build.Tasks.Git (>= 8.0) Microsoft.SourceLink.Common (>= 8.0) - System.Runtime.CompilerServices.Unsafe (4.5.3) - restriction: || (&& (< monoandroid) (< netstandard1.0) (>= netstandard2.0) (< win8)) (&& (< net45) (< netcoreapp2.1) (>= netstandard2.0) (< netstandard2.1) (< xamarintvos) (< xamarinwatchos)) (&& (>= net461) (>= netstandard2.0)) (&& (< netstandard1.0) (>= netstandard2.0) (>= win8)) (&& (>= netstandard2.0) (>= wp8)) - System.Threading.Tasks.Extensions (4.5.4) - restriction: || (&& (>= net461) (>= netstandard2.0)) (&& (< netcoreapp2.1) (>= netstandard2.0) (< netstandard2.1)) + System.Runtime.CompilerServices.Unsafe (4.5.3) - restriction: == netstandard2.0 + System.Threading.Tasks.Extensions (4.5.4) - restriction: == netstandard2.0 System.Runtime.CompilerServices.Unsafe (>= 4.5.3) - restriction: || (&& (< monoandroid) (< monotouch) (< net45) (>= netstandard1.0) (< netstandard2.0) (< win8) (< wpa81) (< xamarintvos) (< xamarinwatchos)) (&& (< monoandroid) (< netstandard1.0) (>= portable-net45+win8+wp8+wpa81) (< win8)) (&& (>= net45) (< netstandard2.0)) (&& (< net45) (< netcoreapp2.1) (>= netstandard2.0) (< xamarinios) (< xamarinmac) (< xamarintvos) (< xamarinwatchos)) (>= net461) (&& (< netstandard1.0) (>= win8)) (&& (< netstandard2.0) (>= wpa81)) (>= wp8) GROUP Benchmarks @@ -893,6 +894,8 @@ NUGET FSharp.Core (7.0.402) Hopac (0.5.1) - restriction: >= net6.0 FSharp.Core (>= 4.5.2) - restriction: >= netstandard2.0 + Microsoft.Bcl.AsyncInterfaces (6.0) + System.Threading.Tasks.Extensions (>= 4.5.4) - restriction: || (>= net461) (&& (>= netstandard2.0) (< netstandard2.1)) Microsoft.CodeCoverage (17.8) - restriction: || (>= net462) (>= netcoreapp3.1) Microsoft.NET.Test.Sdk (17.8) Microsoft.CodeCoverage (>= 17.8) - restriction: || (>= net462) (>= netcoreapp3.1) @@ -915,7 +918,9 @@ NUGET System.Reflection.Metadata (8.0) - restriction: >= netcoreapp3.1 System.Collections.Immutable (>= 8.0) - restriction: || (>= net462) (>= netstandard2.0) System.Memory (>= 4.5.5) - restriction: || (>= net462) (&& (< net6.0) (>= netstandard2.0)) - System.Runtime.CompilerServices.Unsafe (6.0) - restriction: || (&& (>= monoandroid) (>= netcoreapp3.1) (< netstandard1.1)) (&& (< monoandroid) (< netcoreapp2.1) (>= netcoreapp3.1)) (&& (< monoandroid) (>= netcoreapp3.1) (< netstandard1.1)) (&& (< monoandroid) (>= netcoreapp3.1) (< netstandard2.0)) (&& (>= monotouch) (>= netcoreapp3.1)) (&& (>= net45) (>= netcoreapp3.1) (< netstandard2.0)) (&& (>= net461) (>= netcoreapp3.1)) (&& (>= net462) (>= net6.0)) (&& (>= net462) (>= netcoreapp3.1)) (&& (>= net6.0) (< net7.0)) (&& (< net6.0) (>= netcoreapp3.1) (>= xamarinios)) (&& (< net6.0) (>= netcoreapp3.1) (>= xamarinmac)) (&& (< net6.0) (>= netcoreapp3.1) (>= xamarintvos)) (&& (< net6.0) (>= netcoreapp3.1) (>= xamarinwatchos)) (&& (< netcoreapp2.0) (>= netcoreapp3.1)) (&& (>= netcoreapp3.1) (< netstandard1.1) (>= win8)) (&& (>= netcoreapp3.1) (< netstandard2.0) (>= wpa81)) (&& (>= netcoreapp3.1) (>= uap10.1)) + System.Runtime.CompilerServices.Unsafe (6.0) - restriction: || (&& (>= monoandroid) (>= netcoreapp3.1) (< netstandard1.1)) (&& (< monoandroid) (< netcoreapp2.1) (>= netcoreapp3.1)) (&& (< monoandroid) (>= netcoreapp3.1) (< netstandard1.1)) (&& (< monoandroid) (>= netcoreapp3.1) (< netstandard2.0)) (&& (< monoandroid) (< netstandard1.0) (>= netstandard2.0) (< win8)) (&& (>= monotouch) (>= netcoreapp3.1)) (&& (>= net45) (>= netcoreapp3.1) (< netstandard2.0)) (&& (< net45) (< netcoreapp2.1) (>= netstandard2.0) (< netstandard2.1) (< xamarintvos) (< xamarinwatchos)) (>= net461) (&& (>= net462) (>= net6.0)) (&& (>= net462) (>= netcoreapp3.1)) (&& (>= net6.0) (< net7.0)) (&& (< net6.0) (>= netcoreapp3.1) (>= xamarinios)) (&& (< net6.0) (>= netcoreapp3.1) (>= xamarinmac)) (&& (< net6.0) (>= netcoreapp3.1) (>= xamarintvos)) (&& (< net6.0) (>= netcoreapp3.1) (>= xamarinwatchos)) (&& (< netcoreapp2.0) (>= netcoreapp3.1)) (&& (>= netcoreapp3.1) (< netstandard1.1) (>= win8)) (&& (>= netcoreapp3.1) (< netstandard2.0) (>= wpa81)) (&& (>= netcoreapp3.1) (>= uap10.1)) (&& (< netstandard1.0) (>= netstandard2.0) (>= win8)) (&& (>= netstandard2.0) (>= wp8)) + System.Threading.Tasks.Extensions (4.5.4) - restriction: || (>= net461) (&& (>= netstandard2.0) (< netstandard2.1)) + System.Runtime.CompilerServices.Unsafe (>= 4.5.3) - restriction: || (&& (< monoandroid) (< monotouch) (< net45) (>= netstandard1.0) (< netstandard2.0) (< win8) (< wpa81) (< xamarintvos) (< xamarinwatchos)) (&& (< monoandroid) (< netstandard1.0) (>= portable-net45+win8+wp8+wpa81) (< win8)) (&& (>= net45) (< netstandard2.0)) (&& (< net45) (< netcoreapp2.1) (>= netstandard2.0) (< xamarinios) (< xamarinmac) (< xamarintvos) (< xamarinwatchos)) (>= net461) (&& (< netstandard1.0) (>= win8)) (&& (< netstandard2.0) (>= wpa81)) (>= wp8) YoloDev.Expecto.TestSdk (0.14.3) Expecto (>= 10.0 < 11.0) - restriction: >= net6.0 FSharp.Core (>= 7.0.200) - restriction: >= net6.0 diff --git a/src/FsToolkit.ErrorHandling.AsyncSeq/paket.references b/src/FsToolkit.ErrorHandling.AsyncSeq/paket.references index 3320bac5..3df8daa9 100644 --- a/src/FsToolkit.ErrorHandling.AsyncSeq/paket.references +++ b/src/FsToolkit.ErrorHandling.AsyncSeq/paket.references @@ -1,3 +1,4 @@ Microsoft.SourceLink.GitHub FSharp.Core FSharp.Control.AsyncSeq +Microsoft.Bcl.AsyncInterfaces diff --git a/src/FsToolkit.ErrorHandling.IcedTasks/CancellableTaskResultCE.fs b/src/FsToolkit.ErrorHandling.IcedTasks/CancellableTaskResultCE.fs index e5d2fa05..c8648c2e 100644 --- a/src/FsToolkit.ErrorHandling.IcedTasks/CancellableTaskResultCE.fs +++ b/src/FsToolkit.ErrorHandling.IcedTasks/CancellableTaskResultCE.fs @@ -177,7 +177,6 @@ module CancellableTaskResultCE = ) ) -#if NETSTANDARD2_1 || NET6_0_OR_GREATER member inline internal this.TryFinallyAsync ( body: CancellableTaskResultCode<'TOverall, 'Error, 'T>, @@ -239,7 +238,7 @@ module CancellableTaskResultCE = ValueTask() ) ) -#endif + member inline this.Source (ctr: CancellableTaskResult<'T, 'Error>) : CancellableTaskResult<'T, 'Error> = @@ -258,10 +257,9 @@ module CancellableTaskResultCE = |> Async.map Result.ofChoice |> this.Source -#if NETSTANDARD2_1 || NET6_0_OR_GREATER member inline _.Source(t: ValueTask>) : CancellableTaskResult<'T, 'Error> = cancellableTask { return! t } -#endif + member inline _.Source(result: Result<_, _>) : CancellableTaskResult<_, _> = CancellableTask.singleton result diff --git a/src/FsToolkit.ErrorHandling.IcedTasks/CancellableTaskValidationCE.fs b/src/FsToolkit.ErrorHandling.IcedTasks/CancellableTaskValidationCE.fs index 08ff4bed..f6af7999 100644 --- a/src/FsToolkit.ErrorHandling.IcedTasks/CancellableTaskValidationCE.fs +++ b/src/FsToolkit.ErrorHandling.IcedTasks/CancellableTaskValidationCE.fs @@ -175,7 +175,7 @@ module CancellableTaskValidationCE = ) ) ) -#if NETSTANDARD2_1 || NET6_0_OR_GREATER + member inline internal this.TryFinallyAsync ( [] body: CancellableTaskValidationCode<'TOverall, 'Error, 'T>, @@ -238,7 +238,6 @@ module CancellableTaskValidationCE = ValueTask() ) ) -#endif [] static member inline BindDynamic diff --git a/src/FsToolkit.ErrorHandling.IcedTasks/paket.references b/src/FsToolkit.ErrorHandling.IcedTasks/paket.references index e9b80506..1d1df93b 100644 --- a/src/FsToolkit.ErrorHandling.IcedTasks/paket.references +++ b/src/FsToolkit.ErrorHandling.IcedTasks/paket.references @@ -2,3 +2,4 @@ Microsoft.SourceLink.GitHub FSharp.Core IcedTasks +Microsoft.Bcl.AsyncInterfaces diff --git a/src/FsToolkit.ErrorHandling.JobResult/paket.references b/src/FsToolkit.ErrorHandling.JobResult/paket.references index 8bbf3f25..aceb1c1e 100644 --- a/src/FsToolkit.ErrorHandling.JobResult/paket.references +++ b/src/FsToolkit.ErrorHandling.JobResult/paket.references @@ -1,3 +1,4 @@ Microsoft.SourceLink.GitHub FSharp.Core Hopac +Microsoft.Bcl.AsyncInterfaces diff --git a/src/FsToolkit.ErrorHandling.TaskResult/Task.fs b/src/FsToolkit.ErrorHandling.TaskResult/Task.fs index 1e08b46b..855d838b 100644 --- a/src/FsToolkit.ErrorHandling.TaskResult/Task.fs +++ b/src/FsToolkit.ErrorHandling.TaskResult/Task.fs @@ -15,13 +15,13 @@ module Task = return! f x } -#if NETSTANDARD2_1 || NET6_0_OR_GREATER + let inline bindV ([] f: 'a -> Task<'b>) (x: ValueTask<'a>) = task { let! x = x return! f x } -#endif + let inline apply f x = bind (fun f' -> bind (fun x' -> singleton (f' x')) x) f @@ -32,14 +32,12 @@ module Task = >> singleton ) -#if NETSTANDARD2_1 || NET6_0_OR_GREATER let inline mapV ([] f) x = x |> bindV ( f >> singleton ) -#endif let inline map2 ([] f) x y = (apply (apply (singleton f) x) y) diff --git a/src/FsToolkit.ErrorHandling.TaskResult/TaskOptionCE.fs b/src/FsToolkit.ErrorHandling.TaskResult/TaskOptionCE.fs index c52fbdbd..a25c4e0b 100644 --- a/src/FsToolkit.ErrorHandling.TaskResult/TaskOptionCE.fs +++ b/src/FsToolkit.ErrorHandling.TaskResult/TaskOptionCE.fs @@ -4,7 +4,6 @@ open System open System.Threading.Tasks - open System open System.Runtime.CompilerServices open System.Threading @@ -153,7 +152,6 @@ type TaskOptionBuilderBase() = ) ) -#if NETSTANDARD2_1 || NET6_0_OR_GREATER member inline internal this.TryFinallyAsync ( body: TaskOptionCode<'TOverall, 'T>, @@ -213,7 +211,6 @@ type TaskOptionBuilderBase() = ValueTask() ) ) -#endif member inline this.Source(computation: Async<'T option>) : TaskOption<'T> = computation @@ -221,12 +218,9 @@ type TaskOptionBuilderBase() = member inline this.Source(taskOption: TaskOption<'T>) : TaskOption<'T> = taskOption - -#if NETSTANDARD2_1 || NET6_0_OR_GREATER - member inline this.Source(taskOption: ValueTask<'T option>) : TaskOption<'T> = taskOption.AsTask() -#endif + type TaskOptionBuilder() = @@ -607,7 +601,6 @@ module TaskOptionCEExtensionsMediumPriority = return Some() } -#if NETSTANDARD2_1 || NET6_0_OR_GREATER member inline this.Source(t: ValueTask<'T>) : TaskOption<'T> = t |> Task.mapV Some @@ -617,7 +610,6 @@ module TaskOptionCEExtensionsMediumPriority = do! t return Some() } -#endif member inline this.Source(opt: Option<'T>) : TaskOption<'T> = Task.FromResult opt diff --git a/src/FsToolkit.ErrorHandling.TaskResult/TaskResultCE.fs b/src/FsToolkit.ErrorHandling.TaskResult/TaskResultCE.fs index 966fe4fc..f6b6f38f 100644 --- a/src/FsToolkit.ErrorHandling.TaskResult/TaskResultCE.fs +++ b/src/FsToolkit.ErrorHandling.TaskResult/TaskResultCE.fs @@ -4,7 +4,6 @@ open System open System.Threading.Tasks - open System open System.Runtime.CompilerServices open System.Threading @@ -153,7 +152,6 @@ type TaskResultBuilderBase() = ) ) -#if NETSTANDARD2_1 || NET6_0_OR_GREATER member inline internal this.TryFinallyAsync ( body: TaskResultCode<'TOverall, 'Error, 'T>, @@ -215,7 +213,7 @@ type TaskResultBuilderBase() = ValueTask() ) ) -#endif + member inline this.Source(taskResult: TaskResult<'T, 'Error>) : TaskResult<'T, 'Error> = taskResult @@ -224,9 +222,8 @@ type TaskResultBuilderBase() = result |> Async.StartImmediateAsTask -#if NETSTANDARD2_1 || NET6_0_OR_GREATER member inline _.Source(t: ValueTask>) : Task> = task { return! t } -#endif + member inline _.Source(result: Result<_, _>) : Task> = Task.singleton result member inline _.Source(result: Choice<_, _>) : Task> = diff --git a/src/FsToolkit.ErrorHandling.TaskResult/paket.references b/src/FsToolkit.ErrorHandling.TaskResult/paket.references index 53cac18a..ee67a9cd 100644 --- a/src/FsToolkit.ErrorHandling.TaskResult/paket.references +++ b/src/FsToolkit.ErrorHandling.TaskResult/paket.references @@ -1,2 +1,3 @@ FSharp.Core Microsoft.SourceLink.GitHub +Microsoft.Bcl.AsyncInterfaces diff --git a/src/FsToolkit.ErrorHandling/AsyncOptionCE.fs b/src/FsToolkit.ErrorHandling/AsyncOptionCE.fs index 0583eac4..7e7f43db 100644 --- a/src/FsToolkit.ErrorHandling/AsyncOptionCE.fs +++ b/src/FsToolkit.ErrorHandling/AsyncOptionCE.fs @@ -45,10 +45,7 @@ module AsyncOptionCE = [] compensation: unit -> unit ) : Async<'value option> = async.TryFinally(computation, compensation) - - -#if NETSTANDARD2_1 - +#if !FABLE_COMPILER member inline _.TryFinallyAsync ( computation: Async<'value option>, diff --git a/src/FsToolkit.ErrorHandling/AsyncResultCE.fs b/src/FsToolkit.ErrorHandling/AsyncResultCE.fs index 0529c48f..c0b0ebc8 100644 --- a/src/FsToolkit.ErrorHandling/AsyncResultCE.fs +++ b/src/FsToolkit.ErrorHandling/AsyncResultCE.fs @@ -53,9 +53,7 @@ module AsyncResultCE = [] compensation: unit -> unit ) : Async> = async.TryFinally(computation, compensation) - -#if NETSTANDARD2_1 - +#if !FABLE_COMPILER member inline _.TryFinallyAsync ( computation: Async>, @@ -91,8 +89,6 @@ module AsyncResultCE = ) ) #endif - - member inline this.While ( [] guard: unit -> bool, diff --git a/src/FsToolkit.ErrorHandling/AsyncResultOptionCE.fs b/src/FsToolkit.ErrorHandling/AsyncResultOptionCE.fs index b7e07b9a..18488992 100644 --- a/src/FsToolkit.ErrorHandling/AsyncResultOptionCE.fs +++ b/src/FsToolkit.ErrorHandling/AsyncResultOptionCE.fs @@ -43,10 +43,7 @@ module AsyncResultOptionCE = [] compensation: unit -> unit ) : AsyncResultOption<'ok, 'error> = async.TryFinally(computation, compensation) - - -#if NETSTANDARD2_1 - +#if !FABLE_COMPILER member inline _.TryFinallyAsync ( computation: AsyncResultOption<'ok, 'error>, @@ -66,7 +63,6 @@ module AsyncResultOptionCE = Async.TryFinallyAsync(computation, compensation) - member inline this.Using ( resource: 'ok :> IAsyncDisposable, @@ -83,7 +79,6 @@ module AsyncResultOptionCE = ) #endif - member inline this.While ( [] guard: unit -> bool, diff --git a/src/FsToolkit.ErrorHandling/paket.references b/src/FsToolkit.ErrorHandling/paket.references index 53cac18a..ee67a9cd 100644 --- a/src/FsToolkit.ErrorHandling/paket.references +++ b/src/FsToolkit.ErrorHandling/paket.references @@ -1,2 +1,3 @@ FSharp.Core Microsoft.SourceLink.GitHub +Microsoft.Bcl.AsyncInterfaces diff --git a/tests/FsToolkit.ErrorHandling.AsyncSeq.Tests/FsToolkit.ErrorHandling.AsyncSeq.Tests.fsproj b/tests/FsToolkit.ErrorHandling.AsyncSeq.Tests/FsToolkit.ErrorHandling.AsyncSeq.Tests.fsproj index b7247ff5..364e3ec2 100644 --- a/tests/FsToolkit.ErrorHandling.AsyncSeq.Tests/FsToolkit.ErrorHandling.AsyncSeq.Tests.fsproj +++ b/tests/FsToolkit.ErrorHandling.AsyncSeq.Tests/FsToolkit.ErrorHandling.AsyncSeq.Tests.fsproj @@ -1,27 +1,20 @@  - - Exe - net6.0;net7.0 - preview - - - - TargetFramework=netstandard2.0 - - - TargetFramework=netstandard2.0 - - - - - - - - - - - - - - \ No newline at end of file + + Exe + net6.0;net7.0 + preview + + + + + + + + + + + + + diff --git a/tests/FsToolkit.ErrorHandling.AsyncSeq.Tests/paket.references b/tests/FsToolkit.ErrorHandling.AsyncSeq.Tests/paket.references index 61c21fb8..366db104 100644 --- a/tests/FsToolkit.ErrorHandling.AsyncSeq.Tests/paket.references +++ b/tests/FsToolkit.ErrorHandling.AsyncSeq.Tests/paket.references @@ -6,3 +6,4 @@ group Test YoloDev.Expecto.TestSdk Fable.Mocha Fable.Pyxpecto + Microsoft.Bcl.AsyncInterfaces diff --git a/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/Expect.fs b/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/Expect.fs index 2688982b..b382a914 100644 --- a/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/Expect.fs +++ b/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/Expect.fs @@ -18,10 +18,6 @@ module Expect = #endif -#if NETSTANDARD2_0 || NET6_0 - open FSharp.Control.Tasks -#endif - #if FABLE_COMPILER let isOk x message = diff --git a/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/FsToolkit.ErrorHandling.IcedTasks.Tests.fsproj b/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/FsToolkit.ErrorHandling.IcedTasks.Tests.fsproj index 48868ab1..181d3e99 100644 --- a/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/FsToolkit.ErrorHandling.IcedTasks.Tests.fsproj +++ b/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/FsToolkit.ErrorHandling.IcedTasks.Tests.fsproj @@ -1,22 +1,23 @@  - - Exe - net7.0 - - - - - - - - - - - - - - - - - \ No newline at end of file + + Exe + net7.0;net6.0 + + + + + + + + + + + + + + + + + diff --git a/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/paket.references b/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/paket.references index 1d933dbb..73fc962c 100644 --- a/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/paket.references +++ b/tests/FsToolkit.ErrorHandling.IcedTasks.Tests/paket.references @@ -1,5 +1,6 @@ group Test - Expecto - Microsoft.NET.Test.Sdk - YoloDev.Expecto.TestSdk - Fable.Pyxpecto + Expecto + Microsoft.NET.Test.Sdk + YoloDev.Expecto.TestSdk + Fable.Pyxpecto + Microsoft.Bcl.AsyncInterfaces diff --git a/tests/FsToolkit.ErrorHandling.JobResult.Tests/FsToolkit.ErrorHandling.JobResult.Tests.fsproj b/tests/FsToolkit.ErrorHandling.JobResult.Tests/FsToolkit.ErrorHandling.JobResult.Tests.fsproj index 672b769e..41a01547 100644 --- a/tests/FsToolkit.ErrorHandling.JobResult.Tests/FsToolkit.ErrorHandling.JobResult.Tests.fsproj +++ b/tests/FsToolkit.ErrorHandling.JobResult.Tests/FsToolkit.ErrorHandling.JobResult.Tests.fsproj @@ -1,41 +1,32 @@ - - Exe - net6.0;net7.0 - preview - - - - TargetFramework=netstandard2.0 - - - TargetFramework=netstandard2.0 - - - TargetFramework=netstandard2.0 - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file + + Exe + net6.0;net7.0 + preview + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tests/FsToolkit.ErrorHandling.JobResult.Tests/paket.references b/tests/FsToolkit.ErrorHandling.JobResult.Tests/paket.references index 0b251f64..209a9a29 100644 --- a/tests/FsToolkit.ErrorHandling.JobResult.Tests/paket.references +++ b/tests/FsToolkit.ErrorHandling.JobResult.Tests/paket.references @@ -5,3 +5,4 @@ group Test YoloDev.Expecto.TestSdk Fable.Mocha Fable.Pyxpecto + Microsoft.Bcl.AsyncInterfaces diff --git a/tests/FsToolkit.ErrorHandling.TaskResult.Tests/paket.references b/tests/FsToolkit.ErrorHandling.TaskResult.Tests/paket.references index a57ca909..65004021 100644 --- a/tests/FsToolkit.ErrorHandling.TaskResult.Tests/paket.references +++ b/tests/FsToolkit.ErrorHandling.TaskResult.Tests/paket.references @@ -6,3 +6,4 @@ group Test YoloDev.Expecto.TestSdk Fable.Mocha Fable.Pyxpecto + Microsoft.Bcl.AsyncInterfaces diff --git a/tests/FsToolkit.ErrorHandling.Tests/AsyncOptionCE.fs b/tests/FsToolkit.ErrorHandling.Tests/AsyncOptionCE.fs index 018379da..907d4112 100644 --- a/tests/FsToolkit.ErrorHandling.Tests/AsyncOptionCE.fs +++ b/tests/FsToolkit.ErrorHandling.Tests/AsyncOptionCE.fs @@ -261,7 +261,7 @@ let ``AsyncOptionCE using Tests`` = Expect.equal actual (Some data) "Should be ok" Expect.isTrue isFinished "" } -#if NET7_0 +#if !FABLE_COMPILER testCaseAsync "use sync asyncdisposable" <| async { let data = 42 diff --git a/tests/FsToolkit.ErrorHandling.Tests/AsyncResultCE.fs b/tests/FsToolkit.ErrorHandling.Tests/AsyncResultCE.fs index 4c22722f..977f71f2 100644 --- a/tests/FsToolkit.ErrorHandling.Tests/AsyncResultCE.fs +++ b/tests/FsToolkit.ErrorHandling.Tests/AsyncResultCE.fs @@ -281,7 +281,7 @@ let ``AsyncResultCE using Tests`` = Expect.equal actual (Result.Ok data) "Should be ok" Expect.isTrue isFinished "" } -#if NET7_0 +#if !FABLE_COMPILER testCaseAsync "use sync asyncdisposable" <| async { let data = 42 @@ -329,6 +329,7 @@ let ``AsyncResultCE using Tests`` = Expect.isTrue isFinished "" } #endif + testCaseAsync "use! normal wrapped disposable" <| async { let data = 42 diff --git a/tests/FsToolkit.ErrorHandling.Tests/AsyncResultOptionCE.fs b/tests/FsToolkit.ErrorHandling.Tests/AsyncResultOptionCE.fs index 9427740d..34737583 100644 --- a/tests/FsToolkit.ErrorHandling.Tests/AsyncResultOptionCE.fs +++ b/tests/FsToolkit.ErrorHandling.Tests/AsyncResultOptionCE.fs @@ -463,8 +463,7 @@ let ``AsyncResultOptionCE using Tests`` = Expect.equal actual (OkSome data) "Should be ok" } - -#if NET7_0 +#if !FABLE_COMPILER testCaseAsync "use sync asyncdisposable" <| async { let data = 42 diff --git a/tests/FsToolkit.ErrorHandling.Tests/FsToolkit.ErrorHandling.Tests.fsproj b/tests/FsToolkit.ErrorHandling.Tests/FsToolkit.ErrorHandling.Tests.fsproj index b0585dd7..5e611989 100644 --- a/tests/FsToolkit.ErrorHandling.Tests/FsToolkit.ErrorHandling.Tests.fsproj +++ b/tests/FsToolkit.ErrorHandling.Tests/FsToolkit.ErrorHandling.Tests.fsproj @@ -5,12 +5,7 @@ net6.0;net7.0 preview - - - TargetFramework=netstandard2.0 - - - + diff --git a/tests/FsToolkit.ErrorHandling.Tests/paket.references b/tests/FsToolkit.ErrorHandling.Tests/paket.references index 61c21fb8..366db104 100644 --- a/tests/FsToolkit.ErrorHandling.Tests/paket.references +++ b/tests/FsToolkit.ErrorHandling.Tests/paket.references @@ -6,3 +6,4 @@ group Test YoloDev.Expecto.TestSdk Fable.Mocha Fable.Pyxpecto + Microsoft.Bcl.AsyncInterfaces