Skip to content

Conversation

@AdaskoTheBeAsT
Copy link

This pull request updates the project to support .NET 8.0 and 9.0, modernizes the test project setup, and improves test assertions for clarity and maintainability. The most important changes include updating package metadata and dependencies, migrating the test project to the new SDK style and frameworks, and switching from the deprecated Should assertion library to Shouldly throughout the test code.

Project and package updates:

  • Updated nuspec/nuget/Cake.CsvHelper.nuspec to add a README.md reference, specify dependency on CsvHelper version 33.1.0, and include build outputs for net8.0 and net9.0 frameworks. Also added LICENSE and README files to the package.

Test project modernization:

  • Migrated src/Cake.CsvHelper.Tests/Cake.CsvHelper.Tests.csproj from legacy .csproj format targeting .NET Framework 4.6.1 to SDK-style format targeting net8.0 and net9.0. Updated all dependencies to modern NuGet package references.

Testing improvements:

  • Replaced the deprecated Should assertion library with Shouldly in all test files, improving assertion clarity and future compatibility (CsvHelperAliasesTests.cs, CsvHelperTests.cs). [1] [2]
  • Updated all test assertions to use Shouldly idioms (e.g., ShouldBeOfType<T>(), ShouldBe()) for exception and equality checks, replacing older ShouldBeType<T>() and ShouldEqual() calls for more consistent and readable tests. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14] [15]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant