Skip to content

Commit 71147f3

Browse files
authored
Merge pull request #70 from LinqToDB4iSeries/V4.4.1
V4.4.1
2 parents 5d304ce + ef1e0dd commit 71147f3

File tree

230 files changed

+1631
-852
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

230 files changed

+1631
-852
lines changed

Build/linq2db.Default.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
22
<PropertyGroup>
3-
<Version>4.3.0</Version>
3+
<Version>4.4.1</Version>
44

55
<Description>LINQ to DB is a data access technology that provides a run-time infrastructure for managing relational data as objects. This package is a provider for DB2 on the IBM iSeries.</Description>
66
<Authors>Roy Chase, Nikos Sarris</Authors>

Build/linq2db.Tests.props

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
<DefineConstants Condition="$(X86) != ''">$(DefineConstants);X86</DefineConstants>
1010

1111
<AssemblyOriginatorKeyFile>..\..\Build\linq2db.snk</AssemblyOriginatorKeyFile>
12+
<SuppressTfmSupportBuildWarnings>true</SuppressTfmSupportBuildWarnings>
1213
</PropertyGroup>
1314

1415
<ItemGroup>

Directory.Packages.props

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
<Project>
2+
<!--<PropertyGroup>
3+
<CentralPackageTransitivePinningEnabled>true</CentralPackageTransitivePinningEnabled>
4+
</PropertyGroup>-->
25
<!--
36
Known issues:
47
@@ -7,21 +10,21 @@
710
-->
811
<ItemGroup>
912
<!--as stated in issue 1 - packages in this item group shouldn't be duplicated in other groups-->
10-
<PackageVersion Include="linq2db" Version="4.3.0" />
11-
<PackageVersion Include="linq2db.Tools" Version="4.3.0" />
12-
<PackageVersion Include="linq2db.AspNet" Version="4.3.0" />
13-
<PackageVersion Include="linq2db.Remote.Grpc" Version="4.3.0" />
14-
<PackageVersion Include="linq2db.Remote.Wcf" Version="4.3.0" />
13+
<PackageVersion Include="linq2db" Version="4.4.1" />
14+
<PackageVersion Include="linq2db.Tools" Version="4.4.1" />
15+
<PackageVersion Include="linq2db.AspNet" Version="4.4.1" />
16+
<PackageVersion Include="linq2db.Remote.Grpc" Version="4.4.1" />
17+
<PackageVersion Include="linq2db.Remote.Wcf" Version="4.4.1" />
1518
<PackageVersion Include="JetBrains.Annotations" Version="2022.1.0" />
1619
<!--generic packages for source projects-->
1720
<!--generic packages for source projects-->
1821
<PackageVersion Include="System.Data.DataSetExtensions" Version="4.5.0" />
1922
<PackageVersion Include="Microsoft.CSharp" Version="4.7.0" />
20-
<PackageVersion Include="Microsoft.Bcl.AsyncInterfaces" Version="6.0.0" />
23+
<PackageVersion Include="Microsoft.Bcl.AsyncInterfaces" Version="7.0.0" />
2124
<PackageVersion Include="System.ComponentModel.Annotations" Version="5.0.0" />
2225
<!--build support-->
2326
<PackageVersion Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="3.3.3" />
24-
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="6.0.0" />
27+
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="7.0.0" />
2528
<PackageVersion Include="Microsoft.SourceLink.GitHub" Version="1.1.1" />
2629
<PackageVersion Include="Mono.TextTemplating" Version="2.2.1" />
2730
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp" Version="4.2.0" />
@@ -47,7 +50,7 @@
4750
<PackageVersion Include="Net.IBM.Data.Db2" Version="6.0.0.200" />
4851
<PackageVersion Include="Net.IBM.Data.Db2-lnx" Version="6.0.0.200" />
4952
<PackageVersion Include="Net.IBM.Data.Db2-osx" Version="6.0.0.200" />
50-
<PackageVersion Include="Npgsql" Version="7.0.0-preview.7" />
53+
<PackageVersion Include="Npgsql" Version="7.0.1" />
5154
<PackageVersion Include="ClickHouse.Client" Version="5.0.4" />
5255
<PackageVersion Include="Octonica.ClickHouseClient" Version="2.2.9" />
5356
<PackageVersion Include="Microsoft.Data.Sqlite" Version="6.0.8" />
@@ -97,7 +100,7 @@
97100
<ItemGroup>
98101
<!--main version-->
99102
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="6.0.0" />
100-
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="6.0.1" />
103+
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="7.0.0" />
101104
</ItemGroup>
102105

103106
<!--test dependencies-->

Tests/Base/BaselinesWriter.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
namespace Tests
88
{
9-
internal class BaselinesWriter
9+
internal sealed class BaselinesWriter
1010
{
1111
// used to detect baseline overwrites by another test(case)
1212
// case-insensitive to support windoze file system
@@ -24,6 +24,8 @@ internal static void Write(string baselinesPath, string baseline)
2424
var target = "core31";
2525
#elif NET6_0
2626
var target = "net60";
27+
#elif NET7_0
28+
var target = "net70";
2729
#else
2830
#error "Build Target must be specified here."
2931
#endif

Tests/Base/CustomTestContext.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
namespace Tests
44
{
5-
internal class CustomTestContext
5+
internal sealed class CustomTestContext
66
{
77
public static string BASELINE = "key-baseline";
88
public static string TRACE = "key-trace";

Tests/Base/CustomizationSupport/Db2iInterceptor.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,8 @@ public override IEnumerable<string> InterceptTestDataSources(DataSourcesBaseAttr
107107
case ("SqlRowTests", "UpdateRowSelect"):
108108
// Test case uses alias name assertion from generated sql, name sanitization breaks test assertion - Copied to custom tests
109109
case ("TableIDTests", "TableTest"):
110+
// Test case uses guid conversion with custom conversion expression
111+
case ("ConvertExpressionTests", "Issue3791Test"):
110112
return Enumerable.Empty<string>();
111113

112114
//Access client throws a different exception so it is excluded

Tests/Base/Remote/TestGrpcLinqService.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ namespace Tests.Remote
1010

1111
using LinqToDB.Remote.Grpc;
1212

13-
internal class TestGrpcLinqService : GrpcLinqService
13+
internal sealed class TestGrpcLinqService : GrpcLinqService
1414
{
1515
private readonly LinqService _linqService;
1616

Tests/Base/Remote/TestWcfLinqService.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ namespace Tests.Remote
1010

1111
using LinqToDB.Remote.Wcf;
1212

13-
internal class TestWcfLinqService : WcfLinqService
13+
internal sealed class TestWcfLinqService : WcfLinqService
1414
{
1515
private readonly LinqService _linqService;
1616

Tests/Base/TestBase.cs

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
using System.Linq;
77
using System.Linq.Expressions;
88
using System.Text;
9-
109
using LinqToDB;
1110
using LinqToDB.Common;
11+
using LinqToDB.Configuration;
1212
using LinqToDB.Data;
1313
using LinqToDB.Data.RetryPolicy;
1414
using LinqToDB.DataProvider.Informix;
@@ -19,11 +19,9 @@
1919
using LinqToDB.Reflection;
2020
using LinqToDB.Tools;
2121
using LinqToDB.Tools.Comparers;
22-
23-
using Tests.Remote.ServerContainer;
24-
2522
using NUnit.Framework;
2623
using NUnit.Framework.Internal;
24+
using Tests.Remote.ServerContainer;
2725

2826
namespace Tests
2927
{
@@ -162,6 +160,8 @@ static TestBase()
162160
var configName = "CORE31";
163161
#elif NET6_0
164162
var configName = "NET60";
163+
#elif NET7_0
164+
var configName = "NET70";
165165
#elif NET472
166166
var configName = "NET472";
167167
#else
@@ -444,6 +444,20 @@ protected TestDataConnection GetDataConnection(
444444
return res;
445445
}
446446

447+
protected TestDataConnection GetDataConnection(LinqToDBConnectionOptions options)
448+
{
449+
if (options.ConfigurationString?.EndsWith(".LinqService") == true)
450+
{
451+
throw new InvalidOperationException($"Call {nameof(GetDataContext)} for remote context creation");
452+
}
453+
454+
Debug.WriteLine(options.ConfigurationString, "Provider ");
455+
456+
var res = new TestDataConnection(options);
457+
458+
return res;
459+
}
460+
447461
private static readonly MappingSchema _sequentialAccessSchema = new ();
448462
private static readonly MappingSchema _fecSchema = new ();
449463

@@ -1442,10 +1456,6 @@ protected virtual BulkCopyOptions GetDefaultBulkCopyOptions(string configuration
14421456
{
14431457
var options = new BulkCopyOptions();
14441458

1445-
// https://github.com/DarkWanderer/ClickHouse.Client/issues/152
1446-
if (configuration.IsAnyOf(ProviderName.ClickHouseClient))
1447-
options.WithoutSession = true;
1448-
14491459
return options;
14501460
}
14511461
}

Tests/Base/TestProviders/TestNoopProvider.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ protected override void Dispose(bool disposing)
5555
}
5656
}
5757

58-
internal class TestNoopDataReader : DbDataReader
58+
internal sealed class TestNoopDataReader : DbDataReader
5959
{
6060
public override object this[int ordinal] => throw new NotImplementedException();
6161
public override object this[string name] => throw new NotImplementedException();
@@ -92,7 +92,7 @@ internal class TestNoopDataReader : DbDataReader
9292
public override bool Read () => throw new NotImplementedException();
9393
}
9494

95-
internal class TestNoopDbCommand : DbCommand
95+
internal sealed class TestNoopDbCommand : DbCommand
9696
{
9797
private readonly DbParameterCollection _parameters = new TestNoopDbParameterCollection();
9898

@@ -141,7 +141,7 @@ protected override DbTransaction? DbTransaction
141141
protected override DbDataReader ExecuteDbDataReader(CommandBehavior behavior) => new TestNoopDbDataReader();
142142
}
143143

144-
internal class TestNoopDbParameter : DbParameter
144+
internal sealed class TestNoopDbParameter : DbParameter
145145
{
146146
public override DbType DbType { get; set; }
147147

@@ -190,7 +190,7 @@ public override DataRowVersion SourceVersion
190190
public override void ResetDbType() => throw new NotImplementedException();
191191
}
192192

193-
internal class TestNoopDbDataReader : DbDataReader
193+
internal sealed class TestNoopDbDataReader : DbDataReader
194194
{
195195
public override int Depth => throw new NotImplementedException();
196196
public override int FieldCount => throw new NotImplementedException();
@@ -230,7 +230,7 @@ public override void Close() { }
230230
public override bool Read ( ) => false;
231231
}
232232

233-
internal class TestNoopDbParameterCollection : DbParameterCollection
233+
internal sealed class TestNoopDbParameterCollection : DbParameterCollection
234234
{
235235
private List<TestNoopDbParameter> _parameters = new ();
236236

@@ -302,7 +302,7 @@ public static void Init()
302302
public override TableOptions SupportedTableOptions => TableOptions.None;
303303
}
304304

305-
internal class TestNoopSqlBuilder : BasicSqlBuilder
305+
internal sealed class TestNoopSqlBuilder : BasicSqlBuilder
306306
{
307307
public TestNoopSqlBuilder(IDataProvider provider, MappingSchema mappingSchema)
308308
: base(provider, mappingSchema, TestNoopSqlOptimizer.Instance, new SqlProviderFlags())
@@ -317,7 +317,7 @@ protected override void BuildInsertOrUpdateQuery(SqlInsertOrUpdateStatement inse
317317
}
318318
}
319319

320-
internal class TestNoopSqlOptimizer : BasicSqlOptimizer
320+
internal sealed class TestNoopSqlOptimizer : BasicSqlOptimizer
321321
{
322322
public static ISqlOptimizer Instance = new TestNoopSqlOptimizer();
323323

0 commit comments

Comments
 (0)