You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+43-21Lines changed: 43 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,30 +11,34 @@ It is strongly advised to start with the [tutorial](http://docs.mytestedasp.net/
11
11
12
12
## Installation
13
13
14
-
You can install this library using NuGet into your test project (or reference it directly in your `project.json` file). Currently MyTested.AspNetCore.Mvc works with ASP.NET Core MVC 1.0.0.
14
+
You can install this library using NuGet into your test project (or reference it directly in your `project.json` file). Currently `MyTested.AspNetCore.Mvc` works with ASP.NET Core MVC 1.0.0.
15
15
16
16
Install-Package MyTested.AspNetCore.Mvc.Universe
17
17
18
-
This package will include all available assertion methods in your test project, including ones for authentication, database, session, caching and more. If you want only the MVC related features, install `MyTested.AspNetCore.Mvc`. Additionally, if you prefer, you can be more specific by including only some of the packages:
19
-
20
-
-`MyTested.AspNetCore.Mvc.Controllers` - contains setup and assertion methods for controllers
21
-
-`MyTested.AspNetCore.Mvc.Routing` - contains setup and assertion methods for routes
22
-
-`MyTested.AspNetCore.Mvc.Core` - contains setup and assertion methods for MVC core features
23
-
-`MyTested.AspNetCore.Mvc.TempData` - contains setup and assertion methods for `ITempDataDictionary`
24
-
-`MyTested.AspNetCore.Mvc.ViewData` - contains assertion methods for `ViewDataDictionary` and dynamic `ViewBag`
25
-
-`MyTested.AspNetCore.Mvc.ViewActionResults` - contains setup and assertion methods for view action results
26
-
-`MyTested.AspNetCore.Mvc.ViewComponents` - contains setup and assertion methods for view components
27
-
-`MyTested.AspNetCore.Mvc.ViewFeatures` - contains setup and assertion methods for MVC view features
28
-
-`MyTested.AspNetCore.Mvc.Http` - contains setup and assertion methods for HTTP context, request and response
29
-
-`MyTested.AspNetCore.Mvc.Authentication` - contains setup methods for `ClaimsPrincipal`
30
-
-`MyTested.AspNetCore.Mvc.ModelState` - contains setup and assertion methods for `ModelStateDictionary` validations
31
-
-`MyTested.AspNetCore.Mvc.DataAnnotations` - contains setup and assertion methods for data annotation validations
32
-
-`MyTested.AspNetCore.Mvc.EntityFrameworkCore` - contains setup and assertion methods for `DbContext`
33
-
-`MyTested.AspNetCore.Mvc.DependencyInjection` - contains setup methods for dependency injection services
34
-
-`MyTested.AspNetCore.Mvc.Caching` - contains setup and assertion methods for `IMemoryCache`
35
-
-`MyTested.AspNetCore.Mvc.Session` - contains setup and assertion methods for `ISession`
36
-
-`MyTested.AspNetCore.Mvc.Options` - contains setup and assertion methods for `IOptions`
37
-
18
+
This package will include all available assertion methods in your test project, including ones for authentication, database, session, caching and more. If you want only the MVC related features, install `MyTested.AspNetCore.Mvc`. If you want to use the completely **FREE** and **UNLIMITED** version of the library, install only `MyTested.AspNetCore.Mvc.Lite` and no other package. Additionally, if you prefer, you can be more specific by including only some of the packages:
19
+
20
+
-`MyTested.AspNetCore.Mvc.Controllers` - Contains setup and assertion methods for controllers
21
+
-`MyTested.AspNetCore.Mvc.Models` - Contains setup and assertion methods for response and view models
22
+
-`MyTested.AspNetCore.Mvc.Routing` - Contains setup and assertion methods for routes
23
+
-`MyTested.AspNetCore.Mvc.Core` - Contains setup and assertion methods for MVC core features
24
+
-`MyTested.AspNetCore.Mvc.TempData` - Contains setup and assertion methods for `ITempDataDictionary`
25
+
-`MyTested.AspNetCore.Mvc.ViewData` - Contains assertion methods for `ViewDataDictionary` and dynamic `ViewBag`
26
+
-`MyTested.AspNetCore.Mvc.ViewActionResults` - Contains setup and assertion methods for view action results
27
+
-`MyTested.AspNetCore.Mvc.ViewComponents` - Contains setup and assertion methods for view components
28
+
-`MyTested.AspNetCore.Mvc.ViewFeatures` - Contains setup and assertion methods for MVC view features
29
+
-`MyTested.AspNetCore.Mvc.Http` - Contains setup and assertion methods for HTTP context, request and response
30
+
-`MyTested.AspNetCore.Mvc.Authentication` - Contains setup methods for `ClaimsPrincipal`
31
+
-`MyTested.AspNetCore.Mvc.ModelState` - Contains setup and assertion methods for `ModelStateDictionary` validations
32
+
-`MyTested.AspNetCore.Mvc.DataAnnotations` - Contains setup and assertion methods for data annotation validations
33
+
-`MyTested.AspNetCore.Mvc.EntityFrameworkCore` - Contains setup and assertion methods for `DbContext`
34
+
-`MyTested.AspNetCore.Mvc.DependencyInjection` - Contains setup methods for dependency injection services
35
+
-`MyTested.AspNetCore.Mvc.Caching` - Contains setup and assertion methods for `IMemoryCache`
36
+
-`MyTested.AspNetCore.Mvc.Session` - Contains setup and assertion methods for `ISession`
37
+
-`MyTested.AspNetCore.Mvc.Options` - Contains setup and assertion methods for `IOptions`
38
+
-`MyTested.AspNetCore.Mvc.Helpers` - Contains additional helper methods for easier assertions
39
+
40
+
-`MyTested.AspNetCore.Mvc.Lite` - Completely **FREE** and **UNLIMITED** version of the library. It should not be used in combination with any other package. Includes `Controllers`, `ViewActionResults` and `ViewComponents`.
41
+
38
42
After the downloading is complete, just add `using MyTested.AspNetCore.Mvc;` to your source code and you are ready to test in the most elegant and developer friendly way.
Copy file name to clipboardExpand all lines: samples/README.md
+4-3Lines changed: 4 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,9 +5,10 @@ Here you can find a few working samples, which will get you started with the lib
5
5
6
6
## Application Samples
7
7
8
-
- MusicStore - sample showing how to use MyTested.AspNetCore.Mvc with an automatically resolved `TestStartup` class for unit testing controllers, view components and routes. It uses the [official ASP.NET Core MVC sample](https://github.com/aspnet/MusicStore) and [xUnit](http://xunit.github.io/).
8
+
-**MusicStore** - sample showing how to use MyTested.AspNetCore.Mvc with an automatically resolved `TestStartup` class for unit testing controllers, view components and routes. It uses the [official ASP.NET Core MVC sample](https://github.com/aspnet/MusicStore) and [xUnit](http://xunit.github.io/).
9
9
10
10
## Functional Test Samples
11
11
12
-
- ApplicationParts - minimalistic functional sample testing whether controllers are found correctly when registered from external assemblies. Uses manual `Startup` configuration and [NUnit](https://github.com/nunit/dotnet-test-nunit).
13
-
- NoStartup - minimalistic functional sample showing how to use the testing library without any globally configured `Startup` class. Uses [MSTest](https://blogs.msdn.microsoft.com/visualstudioalm/2016/09/01/announcing-mstest-v2-framework-support-for-net-core-1-0-rtm/).
12
+
-**ApplicationParts** - minimalistic functional sample testing whether controllers are found correctly when registered from external assemblies. Uses manual `Startup` configuration and [NUnit](https://github.com/nunit/dotnet-test-nunit).
13
+
-**NoStartup** - minimalistic functional sample showing how to use the testing library without any globally configured `Startup` class. Uses [MSTest](https://blogs.msdn.microsoft.com/visualstudioalm/2016/09/01/announcing-mstest-v2-framework-support-for-net-core-1-0-rtm/).
14
+
-**Lite** - minimalistic functional sample showing how to use the completely **FREE** and **UNLIMITED** version of the library - `MyTested.AspNetCore.Mvc.Lite`. Tests API controllers by using automatically resolved `TestStartup` class and [Moq](https://github.com/moq/moq4).
/// Tests whether <see cref="CreatedResult"/>, <see cref="CreatedAtActionResult"/> or <see cref="CreatedAtRouteResult"/> has the same status code as the provided one.
0 commit comments