JetBrains Rider 2019.2 Help

Running and Debugging Unity Tests

Rider provides the support for Unity tests via its Unit Tests window:

  • Unity tests are discovered from code and from the Unity editor and are automatically added to the Explorer tab of the Unit Tests window.

  • All Rider unit test features are available for Unity tests too including grouping, filtering based on test status, and other. Test output is parsed to make stack traces, class and method names into hyperlinks.

  • You can add new Unity tests either in the Unity editor or in Rider. Unit test classes can be added via the Solution Explorer: in the context menu, select Add and then Play Mode Test or Edit Mode Test.

  • The Unit Tests window allows you to choose which unit test runner you want to use. For example, it could be:

    • Standalone NUnit Launcher: NUnit test runner.

    • Unity Editor - Edit Mode: unit test runner embedded in Unity for running edit mode tests.

  • You can run and debug edit mode Unity tests as you run regular unit tests.

    Unity test context menu

Last modified: 16 September 2019