diff --git a/CHANGELOG.md b/CHANGELOG.md index 6d77b6aa..75ea7351 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Removed +- Removed .NET 6.0 framework target + ### Fixed ### Security diff --git a/Directory.Build.props b/Directory.Build.props index d6733a40..ad772cfd 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -6,7 +6,7 @@ 3 0 dev - 5.4.2 + 5.5.0-alpha-001 diff --git a/Remote.Linq.sln b/Remote.Linq.sln index db122d87..342998fb 100644 --- a/Remote.Linq.sln +++ b/Remote.Linq.sln @@ -41,6 +41,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".global", ".global", "{3FB3 Directory.Build.targets = Directory.Build.targets GlobalAssemblyInfo.cs = GlobalAssemblyInfo.cs nuget.config = nuget.config + README.md = README.md Style.NoDoc.ruleset = Style.NoDoc.ruleset Style.ruleset = Style.ruleset Style.Tests.ruleset = Style.Tests.ruleset diff --git a/src/Remote.Linq.EntityFramework/Remote.Linq.EntityFramework.csproj b/src/Remote.Linq.EntityFramework/Remote.Linq.EntityFramework.csproj index a4997fe2..eb33634b 100644 --- a/src/Remote.Linq.EntityFramework/Remote.Linq.EntityFramework.csproj +++ b/src/Remote.Linq.EntityFramework/Remote.Linq.EntityFramework.csproj @@ -20,4 +20,4 @@ - + \ No newline at end of file diff --git a/src/Remote.Linq.EntityFrameworkCore/Remote.Linq.EntityFrameworkCore.csproj b/src/Remote.Linq.EntityFrameworkCore/Remote.Linq.EntityFrameworkCore.csproj index a2dfbfbf..5c1c5d27 100644 --- a/src/Remote.Linq.EntityFrameworkCore/Remote.Linq.EntityFrameworkCore.csproj +++ b/src/Remote.Linq.EntityFrameworkCore/Remote.Linq.EntityFrameworkCore.csproj @@ -1,7 +1,7 @@  - netstandard2.0;netstandard2.1;net6.0;net8.0 + netstandard2.0;netstandard2.1;net8.0 LINQ,expression-tree,lambda,dynamic,remote,remote-query,multi-tier,n-tier,fluent-interface,entity-framework-core,entity-framework,ef-core,ef Remote linq extensions for EF Core. @@ -23,8 +23,7 @@ - - + \ No newline at end of file diff --git a/src/Remote.Linq.Newtonsoft.Json/Remote.Linq.Newtonsoft.Json.csproj b/src/Remote.Linq.Newtonsoft.Json/Remote.Linq.Newtonsoft.Json.csproj index 4ce35d4e..fbf76111 100644 --- a/src/Remote.Linq.Newtonsoft.Json/Remote.Linq.Newtonsoft.Json.csproj +++ b/src/Remote.Linq.Newtonsoft.Json/Remote.Linq.Newtonsoft.Json.csproj @@ -14,4 +14,4 @@ - + \ No newline at end of file diff --git a/src/Remote.Linq.Text.Json/Remote.Linq.Text.Json.csproj b/src/Remote.Linq.Text.Json/Remote.Linq.Text.Json.csproj index 64c2a7b4..424f04bd 100644 --- a/src/Remote.Linq.Text.Json/Remote.Linq.Text.Json.csproj +++ b/src/Remote.Linq.Text.Json/Remote.Linq.Text.Json.csproj @@ -1,7 +1,7 @@  - netstandard2.0;net6.0 + netstandard2.0;net8.0 remote-linq;json;system-text-json Provides System.Text.Json serialization for Remote.Linq types. false @@ -15,4 +15,4 @@ - + \ No newline at end of file diff --git a/src/Remote.Linq/Async/AsyncQueryableExtensions.cs b/src/Remote.Linq/Async/AsyncQueryableExtensions.cs index 209f7c8c..1938d25f 100644 --- a/src/Remote.Linq/Async/AsyncQueryableExtensions.cs +++ b/src/Remote.Linq/Async/AsyncQueryableExtensions.cs @@ -82,12 +82,12 @@ public static ValueTask FirstAsync(this IQueryable so public static ValueTask FirstOrDefaultAsync(this IQueryable source, Expression> predicate, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.FirstOrDefaultWithPredicate, source, predicate, cancellation); - // NET6.0 and later + // NET8.0 and later public static async ValueTask FirstOrDefaultAsync(this IQueryable source, TSource defaultValue, CancellationToken cancellation = default) => await ExecuteAsync(MethodInfos.Queryable.FirstOrDefault, source, cancellation).ConfigureAwait(false) ?? defaultValue; - // NET6.0 and later + // NET8.0 and later public static async ValueTask FirstOrDefaultAsync(this IQueryable source, Expression> predicate, TSource defaultValue, CancellationToken cancellation = default) => await ExecuteAsync(MethodInfos.Queryable.FirstOrDefaultWithPredicate, source, predicate, cancellation).ConfigureAwait(false) ?? defaultValue; @@ -104,12 +104,12 @@ public static ValueTask SingleAsync(this IQueryable s public static ValueTask SingleOrDefaultAsync(this IQueryable source, Expression> predicate, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.SingleOrDefaultWithPredicate, source, predicate, cancellation); - // NET6.0 and later + // NET8.0 and later public static async ValueTask SingleOrDefaultAsync(this IQueryable source, TSource defaultValue, CancellationToken cancellation = default) => await ExecuteAsync(MethodInfos.Queryable.SingleOrDefault, source, cancellation).ConfigureAwait(false) ?? defaultValue; - // NET6.0 and later + // NET8.0 and later public static async ValueTask SingleOrDefaultAsync(this IQueryable source, Expression> predicate, TSource defaultValue, CancellationToken cancellation = default) => await ExecuteAsync(MethodInfos.Queryable.SingleOrDefaultWithPredicate, source, predicate, cancellation).ConfigureAwait(false) ?? defaultValue; @@ -126,12 +126,12 @@ public static ValueTask LastAsync(this IQueryable sou public static ValueTask LastOrDefaultAsync(this IQueryable source, Expression> predicate, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.LastOrDefaultWithPredicate, source, predicate, cancellation); - // NET6.0 and later + // NET8.0 and later public static async ValueTask LastOrDefaultAsync(this IQueryable source, TSource defaultValue, CancellationToken cancellation = default) => await ExecuteAsync(MethodInfos.Queryable.LastOrDefault, source, cancellation).ConfigureAwait(false) ?? defaultValue; - // NET6.0 and later + // NET8.0 and later public static async ValueTask LastOrDefaultAsync(this IQueryable source, Expression> predicate, TSource defaultValue, CancellationToken cancellation = default) => await ExecuteAsync(MethodInfos.Queryable.LastOrDefaultWithPredicate, source, predicate, cancellation).ConfigureAwait(false) ?? defaultValue; @@ -142,13 +142,13 @@ public static ValueTask ElementAtAsync(this IQueryable ElementAtOrDefaultAsync(this IQueryable source, int index, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.ElementAtOrDefault, source, index, cancellation); -#if NET6_0_OR_GREATER +#if NET8_0_OR_GREATER public static ValueTask ElementAtAsync(this IQueryable source, Index index, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.ElementAt, source, index, cancellation); public static ValueTask ElementAtOrDefaultAsync(this IQueryable source, Index index, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.ElementAtOrDefaultWithSystemIndex, source, index, cancellation); -#endif // NET6_0_OR_GREATER +#endif // NET8_0_OR_GREATER public static ValueTask ContainsAsync(this IQueryable source, TSource item, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.Contains, source, item, cancellation); @@ -197,7 +197,7 @@ public static ValueTask LongCountAsync(this IQueryable s public static ValueTask MinAsync(this IQueryable source, Expression> selector, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.MinWithSelector, source, selector, cancellation); -#if NET6_0_OR_GREATER +#if NET8_0_OR_GREATER public static ValueTask MinAsync(this IQueryable source, IComparer comparer, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.MinWithComparer, source, comparer, cancellation); @@ -206,7 +206,7 @@ public static ValueTask LongCountAsync(this IQueryable s public static ValueTask MinByAsync(this IQueryable source, Expression> keySelector, IComparer comparer, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.MinByWithComparer, source, new object?[] { keySelector, comparer }, cancellation); -#endif // NET6_0_OR_GREATER +#endif // NET8_0_OR_GREATER public static ValueTask MaxAsync(this IQueryable source, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.Max, source, cancellation); @@ -214,7 +214,7 @@ public static ValueTask LongCountAsync(this IQueryable s public static ValueTask MaxAsync(this IQueryable source, Expression> selector, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.MaxWithSelector, source, selector, cancellation); -#if NET6_0_OR_GREATER +#if NET8_0_OR_GREATER public static ValueTask MaxAsync(this IQueryable source, IComparer? comparer, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.MaxWithComparer, source, comparer, cancellation); @@ -223,7 +223,7 @@ public static ValueTask LongCountAsync(this IQueryable s public static ValueTask MaxByAsync(this IQueryable source, Expression> keySelector, IComparer? comparer, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.MaxByWithComparer, source, new object?[] { keySelector, comparer }, cancellation); -#endif // NET6_0_OR_GREATER +#endif // NET8_0_OR_GREATER public static ValueTask SumAsync(this IQueryable source, CancellationToken cancellation = default) => ExecuteAsync(MethodInfos.Queryable.SumInt32, source, cancellation); diff --git a/src/Remote.Linq/MethodInfos.Queryable.cs b/src/Remote.Linq/MethodInfos.Queryable.cs index 932d2447..28409f0d 100644 --- a/src/Remote.Linq/MethodInfos.Queryable.cs +++ b/src/Remote.Linq/MethodInfos.Queryable.cs @@ -127,7 +127,7 @@ internal static class Queryable typeof(IQueryable), typeof(int)); -#if NET6_0_OR_GREATER +#if NET8_0_OR_GREATER internal static readonly MethodInfo ElementAtWithSystemIndex = GetQueryableMethod( nameof(System.Linq.Queryable.ElementAt), typeof(IQueryable), @@ -137,7 +137,7 @@ internal static class Queryable nameof(System.Linq.Queryable.ElementAtOrDefault), typeof(IQueryable), typeof(Index)); -#endif // NET6_0_OR_GREATER +#endif // NET8_0_OR_GREATER internal static readonly MethodInfo First = GetQueryableMethod( nameof(System.Linq.Queryable.First), @@ -194,7 +194,7 @@ internal static class Queryable typeof(IQueryable), typeof(Expression>)); -#if NET6_0_OR_GREATER +#if NET8_0_OR_GREATER internal static readonly MethodInfo MaxWithComparer = GetQueryableMethod( nameof(System.Linq.Queryable.Max), [typeof(TSource)], @@ -213,7 +213,7 @@ internal static class Queryable typeof(IQueryable), typeof(Expression>), typeof(IComparer)); -#endif // NET6_0_OR_GREATER +#endif // NET8_0_OR_GREATER internal static readonly MethodInfo Min = GetQueryableMethod( nameof(System.Linq.Queryable.Min), @@ -225,7 +225,7 @@ internal static class Queryable typeof(IQueryable), typeof(Expression>)); -#if NET6_0_OR_GREATER +#if NET8_0_OR_GREATER internal static readonly MethodInfo MinWithComparer = GetQueryableMethod( nameof(System.Linq.Queryable.Min), [typeof(TSource)], @@ -244,7 +244,7 @@ internal static class Queryable typeof(IQueryable), typeof(Expression>), typeof(IComparer)); -#endif // NET6_0_OR_GREATER +#endif // NET8_0_OR_GREATER internal static readonly MethodInfo SequenceEqualWithComparer = GetQueryableMethod( nameof(System.Linq.Queryable.SequenceEqual), diff --git a/src/Remote.Linq/Remote.Linq.csproj b/src/Remote.Linq/Remote.Linq.csproj index 45369e2e..b6aed47b 100644 --- a/src/Remote.Linq/Remote.Linq.csproj +++ b/src/Remote.Linq/Remote.Linq.csproj @@ -2,14 +2,14 @@ Simply LINQ your remote resources... - netstandard2.0;netstandard2.1;net6.0;net8.0 + netstandard2.0;netstandard2.1;net8.0 LINQ;expression-tree;lambda;dynamic;remote;remote-query;multi-tier;n-tier;fluent-interface Remote Linq is a small and easy to use - yet very powerful - library to translate linq expression trees to strongly typed, serializable object trees and vice versa. It provides functionality to send arbitrary linq queries to a remote service to be applied and executed against any enumerable or queryable data source. - + \ No newline at end of file diff --git a/test/Remote.Linq.Async.Queryable.Tests/Remote.Linq.Async.Queryable.Tests.csproj b/test/Remote.Linq.Async.Queryable.Tests/Remote.Linq.Async.Queryable.Tests.csproj index 0ec88e89..f444c032 100644 --- a/test/Remote.Linq.Async.Queryable.Tests/Remote.Linq.Async.Queryable.Tests.csproj +++ b/test/Remote.Linq.Async.Queryable.Tests/Remote.Linq.Async.Queryable.Tests.csproj @@ -2,7 +2,7 @@ Tests for Remote.Linq.EntityFramework - net48;net6.0;net8.0 + net48;net8.0 diff --git a/test/Remote.Linq.EntityFramework.Tests/Remote.Linq.EntityFramework.Tests.csproj b/test/Remote.Linq.EntityFramework.Tests/Remote.Linq.EntityFramework.Tests.csproj index e8f98cc7..ccdc1f3c 100644 --- a/test/Remote.Linq.EntityFramework.Tests/Remote.Linq.EntityFramework.Tests.csproj +++ b/test/Remote.Linq.EntityFramework.Tests/Remote.Linq.EntityFramework.Tests.csproj @@ -2,7 +2,7 @@ Tests for Remote.Linq.EntityFramework - net48;net6.0;net8.0 + net48;net8.0 diff --git a/test/Remote.Linq.EntityFrameworkCore.Tests/Remote.Linq.EntityFrameworkCore.Tests.csproj b/test/Remote.Linq.EntityFrameworkCore.Tests/Remote.Linq.EntityFrameworkCore.Tests.csproj index c9059603..6d50ee7a 100644 --- a/test/Remote.Linq.EntityFrameworkCore.Tests/Remote.Linq.EntityFrameworkCore.Tests.csproj +++ b/test/Remote.Linq.EntityFrameworkCore.Tests/Remote.Linq.EntityFrameworkCore.Tests.csproj @@ -2,7 +2,7 @@ Tests for Remote.Linq.EntityFrameworkCore - net48;net6.0;net8.0 + net48;net8.0 @@ -11,8 +11,7 @@ - - + \ No newline at end of file diff --git a/test/Remote.Linq.Tests/Remote.Linq.Tests.csproj b/test/Remote.Linq.Tests/Remote.Linq.Tests.csproj index f0bafdf8..1f70c116 100644 --- a/test/Remote.Linq.Tests/Remote.Linq.Tests.csproj +++ b/test/Remote.Linq.Tests/Remote.Linq.Tests.csproj @@ -2,7 +2,7 @@ Tests for Remote.Linq - net48;net6.0;net8.0 + net48;net8.0 diff --git a/test/Remote.Linq.Tests/RemoteQueryable/When_running_query.cs b/test/Remote.Linq.Tests/RemoteQueryable/When_running_query.cs index ab9733a8..f0922dfa 100644 --- a/test/Remote.Linq.Tests/RemoteQueryable/When_running_query.cs +++ b/test/Remote.Linq.Tests/RemoteQueryable/When_running_query.cs @@ -941,9 +941,9 @@ public void Should_query_primitive_value_injected_as_variable_closure(Type type, SystemTextJsonSerializationHelper.SkipUnsupportedDataType(type, value); } -#if NET5_0_OR_GREATER +#if NET8_0_OR_GREATER Skip.If(type.Is(), $"{type} not supported by serializers"); -#endif // NET5_0_OR_GREATER +#endif // NET8_0_OR_GREATER RunTestMethod( nameof(TestMethodFor_Should_query_primitive_value_injected_as_variable_closure), @@ -976,9 +976,9 @@ public void Should_query_primitive_value_collection_injected_as_variable_closure SystemTextJsonSerializationHelper.SkipUnsupportedDataType(type, value); } -#if NET5_0_OR_GREATER +#if NET8_0_OR_GREATER Skip.If(type.Is(), $"{type} not supported by serializers"); -#endif // NET5_0_OR_GREATER +#endif // NET8_0_OR_GREATER RunTestMethod( nameof(TestMethodFor_Should_query_primitive_value_collection_injected_as_variable_closure), @@ -1009,9 +1009,9 @@ public void Should_query_anonymous_type_with_primitive_value_injected_as_variabl { SystemTextJsonSerializationHelper.SkipUnsupportedDataType(type, value); } -#if NET5_0_OR_GREATER +#if NET8_0_OR_GREATER Skip.If(type.Is(), $"{type} not supported by serializers"); -#endif // NET5_0_OR_GREATER +#endif // NET8_0_OR_GREATER RunTestMethod( nameof(TestMethodFor_Should_query_anonymous_type_with_primitive_value_injected_as_variable_closure), @@ -1043,9 +1043,9 @@ public void Should_query_anonymous_type_with_primitive_value_collection_injected { SystemTextJsonSerializationHelper.SkipUnsupportedDataType(type, value); } -#if NET5_0_OR_GREATER +#if NET8_0_OR_GREATER Skip.If(type.Is(), $"{type} not supported by serializers"); -#endif // NET5_0_OR_GREATER +#endif // NET8_0_OR_GREATER RunTestMethod( nameof(TestMethodFor_Should_query_anonymous_type_with_primitive_value_collection_injected_as_variable_closure), diff --git a/test/Remote.Linq.Tests/Serialization/ProtobufNetSerializationHelper.cs b/test/Remote.Linq.Tests/Serialization/ProtobufNetSerializationHelper.cs index e9d85f1f..9f9ad5d7 100644 --- a/test/Remote.Linq.Tests/Serialization/ProtobufNetSerializationHelper.cs +++ b/test/Remote.Linq.Tests/Serialization/ProtobufNetSerializationHelper.cs @@ -60,8 +60,8 @@ public static void SkipUnsupportedDataType(Type type, object value) Skip.If(type.Is(), $"{type} not supported by out-of-the-box protobuf-net"); Skip.If(type.Is(), $"{type} not supported by out-of-the-box protobuf-net"); Skip.If(type.IsNotPublic(), $"Not-public {type} not supported protobuf-net"); -#if NET5_0_OR_GREATER +#if NET8_0_OR_GREATER Skip.If(type.Is(), $"{type} not supported by serializers"); -#endif // NET5_0_OR_GREATER +#endif // NET8_0_OR_GREATER } } \ No newline at end of file diff --git a/test/Remote.Linq.Tests/TestData.cs b/test/Remote.Linq.Tests/TestData.cs index 6b09c0bc..d4ada279 100644 --- a/test/Remote.Linq.Tests/TestData.cs +++ b/test/Remote.Linq.Tests/TestData.cs @@ -73,11 +73,11 @@ public enum Custom new Complex(-87654, 234), new Complex(double.MinValue, double.MinValue), new Complex(double.MaxValue, double.MaxValue), -#if NET5_0_OR_GREATER +#if NET8_0_OR_GREATER (Half)Math.PI, Half.MinValue, Half.MaxValue, -#endif // NET5_0_OR_GREATER +#endif // NET8_0_OR_GREATER new { Text = string.Empty, Timestamp = default(DateTime?) }, } .SelectMany(x => new (Type Type, object Value)[]