Join Kit Eason for an in-depth discussion in this video Exercise solution: Converting tests to use Expecto, part of F#: Automated Testing for Developers.
- [Instructor] Hopefully, that exercise…didn't give you too much trouble.…You just need to copy across the code from the test here…into your program.fs,…inside of the let binding site yield testProp,…and change this to a label to the function name.…At the end, make sure you've got the backwards pipe.…Then, to clear the body of the test is a lambda function,…with the same arguments as before.…Then, this code here has just been indented slightly…to make it's fully inside the lambda.…
And then, the only other change I had to make…was to take out these unquote operators.…Replace them with equals comparisons…and and them together,…and that should work just fine.…
Author
Released
6/15/2017Kit Eason explains how to use xUnit—a .NET unit-testing package—to do some test-driven development, and demonstrates how to improve your test run experience using NCrunch, a test runner. He shows how to use FsCheck to generate test cases, and how to use Expecto to move into the world of tests as first-class values. He also covers the use of Canopy to automate the testing of web user interfaces, and of mocking to tame dependencies.
- Solving issues with early versions of Visual Studio 2017
- Classical unit testing with F#
- Creating a testable project and installing Paket and xUnit
- Test driving an implementation
- Improving your test run experience with NCrunch
- Going beyond test cases with FsCheck and Unquote
- Making tests first class using Expecto
- Using mocking to tame dependencies
- Web UI testing with Canopy
Skill Level Intermediate
Duration
Views
Related Courses
-
Developing Financial Applications in F#
with Kit Eason2h 51m Intermediate -
Visual Studio 2017: First Look
with Walt Ritscher1h 54m Beginner -
F# and Xamarin Development Basics
with Rachel Blasucci56m 43s Intermediate
-
Introduction
-
Welcome1m 7s
-
Working with the sample code2m 58s
-
-
1. Introducing Automated Testing
-
2. Classical Unit Testing with F#
-
Creating your first tests5m 55s
-
3. Improving Your Test Run Experience with NCrunch
-
Organizing tests in NCrunch3m 51s
-
4. Going Beyond Test Cases with FsCheck and Unquote
-
5. Making Tests First Class Using Expecto
-
Writing tests in Expecto6m 17s
-
6. Using Mocking to Tame Dependencies
-
Introducing mocking with Foq4m 42s
-
-
7. User Interface Testing
-
Web UI testing with Canopy12m 43s
-
-
Conclusion
-
Next steps52s
-
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.
CancelTake notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.
Share this video
Embed this video
Video: Exercise solution: Converting tests to use Expecto