Skip to content

Commit 1276642

Browse files
committed
perf tests: clean up SqlClient warning
1 parent 1825767 commit 1276642

File tree

6 files changed

+9
-9
lines changed

6 files changed

+9
-9
lines changed

benchmarks/Dapper.Tests.Performance/Benchmarks.HandCoded.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
using System;
33
using System.ComponentModel;
44
using System.Data;
5-
using System.Data.SqlClient;
5+
using Microsoft.Data.SqlClient;
66

77
namespace Dapper.Tests.Performance
88
{

benchmarks/Dapper.Tests.Performance/Benchmarks.RepoDB.cs

+4-4
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@ public void Setup()
2020
// We need this since benchmarks using System.Data.SqlClient
2121
var dbSetting = new SqlServerDbSetting();
2222
DbSettingMapper
23-
.Add<System.Data.SqlClient.SqlConnection>(dbSetting, true);
23+
.Add<Microsoft.Data.SqlClient.SqlConnection>(dbSetting, true);
2424
DbHelperMapper
25-
.Add<System.Data.SqlClient.SqlConnection>(new SqlServerDbHelper(), true);
25+
.Add<Microsoft.Data.SqlClient.SqlConnection>(new SqlServerDbHelper(), true);
2626
StatementBuilderMapper
27-
.Add<System.Data.SqlClient.SqlConnection>(new SqlServerStatementBuilder(dbSetting), true);
27+
.Add<Microsoft.Data.SqlClient.SqlConnection>(new SqlServerStatementBuilder(dbSetting), true);
2828

2929
ClassMapper.Add<Post>("Posts");
3030
}
@@ -54,7 +54,7 @@ public Post QueryDynamic()
5454
public Post QueryField()
5555
{
5656
Step();
57-
return _connection.Query<Post>(new QueryField[] { new(nameof(Post.Id), i) }).First();
57+
return _connection.Query<Post>([new(nameof(Post.Id), i)]).First();
5858
}
5959

6060
[Benchmark(Description = "ExecuteQuery<T>")]

benchmarks/Dapper.Tests.Performance/Benchmarks.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using BenchmarkDotNet.Attributes;
22
using System;
33
using System.Configuration;
4-
using System.Data.SqlClient;
4+
using Microsoft.Data.SqlClient;
55

66
namespace Dapper.Tests.Performance
77
{

benchmarks/Dapper.Tests.Performance/LegacyTests.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using System;
22
using System.Collections.Generic;
33
using System.Data;
4-
using System.Data.SqlClient;
4+
using Microsoft.Data.SqlClient;
55
using System.Diagnostics;
66
using System.Linq;
77

benchmarks/Dapper.Tests.Performance/Program.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using BenchmarkDotNet.Running;
22
using System;
3-
using System.Data.SqlClient;
3+
using Microsoft.Data.SqlClient;
44
using System.Linq;
55
using static System.Console;
66

benchmarks/Dapper.Tests.Performance/SqlDataReaderHelper.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
using System;
2-
using System.Data.SqlClient;
2+
using Microsoft.Data.SqlClient;
33
using System.Runtime.CompilerServices;
44

55
namespace Dapper.Tests.Performance

0 commit comments

Comments
 (0)