This repository has been archived by the owner on Feb 22, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 33
Unit tests
Ian Auty edited this page May 11, 2020
·
7 revisions
MMALSharp has a suite of unit tests covering almost all functionality currently available. Our unit tests use the xUnit framework and a few preliminary steps must be carried out before running them.
- First, grab MMALSharp from source and build the library in Visual Studio. The published binaries will then be outputted to the
bin/Debug/net472/
directory. - Copy the published binaries to a new folder on your Pi - I'll be copying to the directory
/home/pi/Source/MMALSharpTests
in this tutorial. - Copy
xunit.runner.console
v2.4.1 over to your Pi. This will be located in your NuGet packages folder. - Open a new console window on your Pi locally, or SSH to your Pi via PuTTY in Windows.
- cd to
xunit.runner.console/2.4.1/tools/net472
. - Run
mono --debug xunit.console.exe /home/pi/Source/MMALSharpTests/MMALSharp.Tests.dll -parallel none -maxthreads 1 -verbose
. Note we have used the parallel flag and maxthreads in order to turn off parallelism, this is because only one instance of MMALSharp can be running at any given time.