StoicDreams.TestFramework
0.1.9
See the version list below for details.
dotnet add package StoicDreams.TestFramework --version 0.1.9
NuGet\Install-Package StoicDreams.TestFramework -Version 0.1.9
<PackageReference Include="StoicDreams.TestFramework" Version="0.1.9" />
paket add StoicDreams.TestFramework --version 0.1.9
#r "nuget: StoicDreams.TestFramework, 0.1.9"
// Install StoicDreams.TestFramework as a Cake Addin #addin nuget:?package=StoicDreams.TestFramework&version=0.1.9 // Install StoicDreams.TestFramework as a Cake Tool #tool nuget:?package=StoicDreams.TestFramework&version=0.1.9
Stoic Dreams Test Framework
Nuget: StoicDreams.TestFramework
This library includes an abstract
class to access helper methods for unit and integration tests.
Functionality includes extending and simplifying functionality from the Moq
mocking framework.
Project Goals
The goal of this library is to provide a framework to use in unit tests and integration tests that grealy simplify organizing tests using the Arrange / Act / Assert testing pattern.
Framework Features
- Inclusion of Moq mocking framework to use for mocking components.
- Inclusion of FLuentAssertions framework to use for human readable assertions.
- Automatic default mocking (using Moq's Mock framework) of a class's constructor dependencies when running unit tests.
- Test framework agnostic: While we use XUnit, we have not restrictions against using other frameworks such as NUnit, MSTest, etc.
Noted Restrictions
This framework assumes use of IServiceCollection and IServiceProvider to handle dependency injection. And so, also uses ServiceCollection to manage components and build IServiceProvider which is used to handle dependency injection. Because of this usage:
- Classes being tested with
TestFramework.ArrangeUnitTest
should have a single public constructor.
Setting up your Test Project
Add the StoicDreams.TestFramework
Nuget package to your test project.
<ItemGroup>
<PackageReference Include="StoicDreams.TestFramework" Version="0.1.9" />
</ItemGroup>
Author
- Erik Gassler - Stoic Dreams - Just a simpleton who likes making stuff with bits and bytes. Visit my Patreon page if you would like to provide support.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net6.0
- FluentAssertions (>= 6.7.0)
- Microsoft.Extensions.DependencyInjection (>= 6.0.0)
- Moq (>= 4.18.1)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on StoicDreams.TestFramework:
Package | Downloads |
---|---|
StoicDreams.TestFramework.Blazor
Extended functionality of Stoic Dreams Test Framework, adding funtionality to handle testing against rendered .razor components for unit and integration testing. |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
1.6.7 | 1,121 | 5/25/2024 |
1.6.6 | 105 | 5/25/2024 |
1.6.5 | 115 | 5/24/2024 |
1.6.4 | 127 | 5/24/2024 |
1.6.3 | 1,149 | 1/4/2024 |
1.6.2 | 517 | 12/7/2023 |
1.6.1 | 261 | 11/16/2023 |
1.6.0 | 201 | 11/15/2023 |
1.5.16 | 203 | 11/15/2023 |
1.5.15 | 1,079 | 10/17/2023 |
1.5.14 | 1,388 | 8/29/2023 |
1.5.13 | 694 | 8/17/2023 |
1.5.12 | 513 | 8/11/2023 |
1.5.11 | 297 | 8/11/2023 |
1.5.10 | 297 | 8/11/2023 |
1.5.9 | 297 | 8/11/2023 |
1.5.8 | 306 | 8/11/2023 |
1.5.7 | 296 | 8/11/2023 |
1.5.6 | 286 | 8/11/2023 |
1.5.5 | 300 | 8/11/2023 |
1.5.4 | 315 | 8/11/2023 |
1.5.3 | 291 | 8/11/2023 |
1.5.2 | 168 | 8/10/2023 |
1.5.1 | 145 | 8/10/2023 |
1.4.53 | 316 | 7/30/2023 |
1.4.51 | 4,496 | 4/4/2023 |
1.4.50 | 335 | 4/4/2023 |
1.4.49 | 1,544 | 3/1/2023 |
1.4.48 | 1,170 | 2/3/2023 |
1.4.40 | 526 | 1/24/2023 |
1.4.37 | 410 | 1/24/2023 |
1.4.36 | 725 | 1/5/2023 |
1.4.32 | 442 | 1/5/2023 |
1.4.31 | 439 | 1/5/2023 |
1.4.30 | 436 | 1/5/2023 |
1.4.21 | 499 | 1/3/2023 |
1.4.20 | 504 | 12/12/2022 |
1.4.9 | 930 | 9/20/2022 |
1.4.7 | 787 | 8/28/2022 |
1.4.2 | 1,189 | 8/11/2022 |
1.4.1 | 4,912 | 7/17/2022 |
1.3.1 | 692 | 7/17/2022 |
1.2.12 | 672 | 7/17/2022 |
1.2.11 | 724 | 7/11/2022 |
1.2.10 | 678 | 7/9/2022 |
1.2.8 | 711 | 7/9/2022 |
1.2.7 | 690 | 7/9/2022 |
1.2.6 | 697 | 7/9/2022 |
1.2.4 | 677 | 7/9/2022 |
1.2.3 | 662 | 7/8/2022 |
1.1.14 | 682 | 7/8/2022 |
1.1.13 | 687 | 7/8/2022 |
1.1.12 | 399 | 7/8/2022 |
1.1.11 | 403 | 7/8/2022 |
1.1.10 | 400 | 7/8/2022 |
1.1.9 | 686 | 7/8/2022 |
1.1.5 | 408 | 7/8/2022 |
1.0.4 | 427 | 7/7/2022 |
1.0.3 | 422 | 7/4/2022 |
1.0.2 | 389 | 7/3/2022 |
0.1.13 | 415 | 7/3/2022 |
0.1.12 | 399 | 7/3/2022 |
0.1.11 | 411 | 7/3/2022 |
0.1.10 | 407 | 7/3/2022 |
0.1.9 | 419 | 7/3/2022 |
Development Release