Fabricam Leads is a sample app to show data concurrency and unit testing.
-
Download and install Docker CE. Note: Docker for Windows sits atop Hyper-V which requires Windows 10 Pro or better patched to Anniversary Update or better.
-
Clone this repo
-
docker-compose up
will build and run all the containers -
Watch the console output to see the C# unit tests pass and the application start up
-
Browse to http://localhost:5000/ and click through the app.
Look at Sql/setup.sql
for the stored procedure that checks out exactly one lead, marking it as checked out as we go. This ensures a lead is only presented to exactly one person.
There are unit tests in:
- UserApi.Tests: these tests validate the UserApi service
- WebCore.Tests: these tests validate critical pieces of the Web.Core project
- http://localhost:5000/Lead/JavaScriptTests: these tests validate the Vue application services on the Leads page
This sample could benefit from integration testing:
-
Web.Core/Services/LoadLeadsService: an integration test could validate integration with both the db and http://randomuser.me/
-
Web.Core/Services/AuthenticateService: an integration test could validate integration with UserApi microservice
-
Web: selenium tests could validate the site pulls up correctly and functions as expected
-
Sql: tSQLt could validate the stored procedure works as expected
- License: MIT
- Copyright: Richardson
- IsLawyer: no
- CanUse: yes