Skip to content

Commit a22e261

Browse files
committed
Update Other Dependencies
1 parent 2009c8e commit a22e261

File tree

2 files changed

+34
-2
lines changed

2 files changed

+34
-2
lines changed
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
using System.Reflection;
2+
using Shouldly;
3+
using Xunit;
4+
5+
namespace DbUp.SqlServer.Tests;
6+
7+
public class MicrosoftDataSqlClientVersionTests
8+
{
9+
[Fact]
10+
public void Microsoft_Data_SqlClient_Is_Lowest_Supported_Lts()
11+
{
12+
var assembly = typeof(Microsoft.Data.SqlClient.SqlConnection).Assembly;
13+
var version = assembly.GetCustomAttribute<AssemblyInformationalVersionAttribute>();
14+
15+
// https://learn.microsoft.com/en-us/sql/connect/ado-net/sqlclient-driver-support-lifecycle
16+
version.ShouldNotBeNull();
17+
version.InformationalVersion.ShouldStartWith("6.1.", customMessage: "We want to stay on 6.1.x as it is the lowest LTS version which is in support (ends 14 Aug, 2028)");
18+
}
19+
20+
[Fact]
21+
public void Microsoft_Data_SqlClient_Is_In_Support()
22+
{
23+
// Arrange
24+
var supportEndDate = new DateTime(2028, 8, 14);
25+
var currentDate = DateTime.UtcNow;
26+
27+
// Assert
28+
currentDate.ShouldBeLessThanOrEqualTo(supportEndDate,
29+
$"Microsoft.Data.SqlClient 6.1.x support ends on {supportEndDate:yyyy-MM-dd}. " +
30+
$"Current date is {currentDate:yyyy-MM-dd}. We should upgrade to the latest lowest lts https://learn.microsoft.com/en-us/sql/connect/ado-net/sqlclient-driver-support-lifecycle.");
31+
}
32+
}

src/dbup-sqlserver/dbup-sqlserver.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@
2424
</PropertyGroup>
2525

2626
<ItemGroup>
27-
<PackageReference Include="dbup-core" Version="6.0.3"/>
28-
<PackageReference Include="Microsoft.Data.SqlClient" Version="5.2.2" />
27+
<PackageReference Include="dbup-core" Version="6.0.15" />
28+
<PackageReference Include="Microsoft.Data.SqlClient" Version="6.1.2" />
2929
</ItemGroup>
3030

3131
<ItemGroup>

0 commit comments

Comments
 (0)