Skip to content

JetBrains/teamcity-dotmemory

Repository files navigation

JetBrains dotMemory Unit plugin for

This plugin provides the ability to run a build step under JetBrains dotMemory Unit for the .Net related build runners in TeamCity.

The proposed scenario has the following steps:

  • create a solution with a test project
  • add the NuGet package for the JetBrains dotMemory Unit
  • implement tests using JetBrains dotMemory Unit
  • create a build project and a configuration using the TeamCity build server
  • add a build step to restore NuGet packages, for example NuGet.exe restore testproj\packages.config -PackagesDirectory testproj\packages
  • add a build step to build the project
  • add a build step to run memory tests and turn on "Run build step under JetBrains dotMemory Unit", use the "Path to dotMemoryUnit.exe" field to specify the path to the JetBrains dotMemory Unit profiler, for example %system.teamcity.build.checkoutDir%\testproj\packages\JetBrains.dotMemoryUnit.2.0.20150814.155607-RC3\tools, use the "Path for storing workspaces" field to specify the path to the directory which will be used by the JetBrains dotMemory Unit to store workspaces.

✔️ Now it aslo compatible with .NET CLI Plugin

Installation

To install the plugin, put the zip archive into the 'plugins' directory under the TeamCity Data Directory. Restart the server.

## Deployment of the JetBrains dotMemory Unit profiling command-line tool to a TeamCity agent ##

JetBrains dotMemory Unit is a unit testing framework allowing you to write tests that check your code for all kinds of memory issues. To run memory tests using JetBrains dotMemory Unit testing framework on TeamCity, you need to have the JetBrains dotMemory Unit profiling command-line tool on the each TeamCity agent where tests will be run. There are two ways to deploy the command-line tool to the TeamCity agent:

  • Add a reference to the NuGet package for the JetBrains dotMemory Unit from your project. In this case you can specify a relative path to dotMemoryUnit.exe, for example %system.teamcity.build.checkoutDir%\testproj\packages\JetBrains.dotMemoryUnit.2.0.20150814.155607-RC3\tools. Add a step to restore this package before the tests' run.
  • Download a free stand-alone runner from the JetBrains dotMemory Unit page.

Build

Use the 'mvn package' command from the root project to build your plugin. The resulting package 'dotMemoryUnit.zip' will be placed in the 'target' directory. The build is configured on the JetBrains TeamCity build server.

License

JetBrains dotMemory Unit plugin for TeamCity is under the Apache License.

Resources