-
In Visual Studio, create a new console project. (PetaTest projects are executables - not assemblies)
-
Install PetaTest using Nuget. You'll need to agree to the license after which Nuget will add PetaTest.cs to your project.
PM> Install-Package PetaTest
-
In
program.cs
add ausing
clause forPetaTest
using PetaTest;
-
In
Main()
call PetaTest's Runner:static int Main(string[] args) { PetaTest.Runner.RunMain(args); return 0; }
-
Create a test fixture and test case:
[TestFixture] public class MyTests { [Test] public void Test1() { Assert.AreNotEqual("PetaTest", "NUnit"); } }
-
Run the project and PetaTest will execute all your tests.