TestIT.Adapter
3.0.1
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package TestIT.Adapter --version 3.0.1
NuGet\Install-Package TestIT.Adapter -Version 3.0.1
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="TestIT.Adapter" Version="3.0.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="TestIT.Adapter" Version="3.0.1" />
<PackageReference Include="TestIT.Adapter" />
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add TestIT.Adapter --version 3.0.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: TestIT.Adapter, 3.0.1"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package TestIT.Adapter@3.0.1
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=TestIT.Adapter&version=3.0.1
#tool nuget:?package=TestIT.Adapter&version=3.0.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Test IT TMS Adapter for MsTest/NUnit

Getting Started
Installation
Requirements
- MethodBoundaryAspect.Fody 2.0.148+
- Microsoft.NET.Test.Sdk 17.5.0+
- MSTest.TestAdapter 3.0.2 (only for MSTest)
- MSTest.TestFramework 3.0.2 (only for MSTest)
NuGet CLI
Install-Package TestIt.Adapter
.NET CLI
dotnet package add TestIt.Adapter
Usage
Configuration
| Description | File property | Environment variable | CLI argument |
|---|---|---|---|
| Location of the TMS instance | url | TMS_URL | tmsUrl |
| API secret key How to getting API secret key? | privateToken | TMS_PRIVATE_TOKEN | tmsPrivateToken |
| ID of project in TMS instance How to getting project ID? | projectId | TMS_PROJECT_ID | tmsProjectId |
| ID of configuration in TMS instance How to getting configuration ID? | configurationId | TMS_CONFIGURATION_ID | tmsConfigurationId |
| ID of the created test run in TMS instance.<br/>It's necessary for adapterMode 0 or 1 | testRunId | TMS_TEST_RUN_ID | tmsTestRunId |
| Parameter for specifying the name of test run in TMS instance (It's optional). If it is not provided, it is created automatically | testRunName | TMS_TEST_RUN_NAME | tmsTestRunName |
| Tags of the test run (It's optional). Comma-separated list or JSON array. Applied on create or merged into an existing run at startup | testRunTags | TMS_TEST_RUN_TAGS | tmsTestRunTags |
Links of the test run (It's optional). JSON array of objects with required url and optional title, description, type. Applied on create or merged at startup (e.g. CI job URL while run is In progress) |
testRunLinks | TMS_TEST_RUN_LINKS | tmsTestRunLinks |
| Adapter mode. Default value - 0. The adapter supports following modes:<br/>0 - in this mode, the adapter filters tests by test run ID and configuration ID, and sends the results to the test run<br/>1 - in this mode, the adapter sends all results to the test run without filtering<br/>2 - in this mode, the adapter creates a new test run and sends results to the new test run | adapterMode | TMS_ADAPTER_MODE | tmsAdapterMode |
| It enables/disables certificate validation (It's optional). Default value - true | certValidation | TMS_CERT_VALIDATION | tmsCertValidation |
| It enables/disables parameters processing in autotests (It's optional). Default value - false. The adapter supports following modes:<br/>true - in this mode, the adapter will not process parameters<br/>false - in this mode, the adapter will process parameters | ignoreParameters | TMS_IGNORE_PARAMETERS | tmsIgnoreParameters |
| Mode of automatic creation test cases (It's optional). Default value - false. The adapter supports following modes:<br/>true - in this mode, the adapter will create a test case linked to the created autotest (not to the updated autotest)<br/>false - in this mode, the adapter will not create a test case | automaticCreationTestCases | TMS_AUTOMATIC_CREATION_TEST_CASES | tmsAutomaticCreationTestCases |
| Mode of automatic updation links to test cases (It's optional). Default value - false. The adapter supports following modes:<br/>true - in this mode, the adapter will update links to test cases<br/>false - in this mode, the adapter will not update link to test cases | automaticUpdationLinksToTestCases | TMS_AUTOMATIC_UPDATION_LINKS_TO_TEST_CASES | tmsAutomaticUpdationLinksToTestCases |
| List of labels for filtering tests (Optional). It will only work with adapter mode 2. | - | - | tmsLabelsOfTestsToRun |
| Number of times to rerun failed tests (It's optional). Default value - 0. | rerunTestsCount | TMS_ADAPTER_AUTOTESTS_RERUN_COUNT | tmsRerunTestsCount |
| Mode of import type selection when launching autotests (It's optional). Default value - true. true — create/update each autotest in real time; false — buffer results and publish to the test run at the end (first result is still sent as InProgress via Sync Storage) | importRealtime | TMS_IMPORT_REALTIME | tmsImportRealtime |
| Sync Storage local port (It's optional, 49152 by default) | syncStoragePort | TMS_SYNC_STORAGE_PORT | tmsSyncStoragePort |
| Path to the configuration file (including extension) If it is not provided, it is used default file (It's optional) | - | TMS_CONFIG_FILE | tmsConfigFile |
| The content of the "RunSettings" file with the test run settings in the xml extension (It's optional) | - | - | tmsRunSettings |
File
Create Tms.config.json file in the project directory:
{
"url": "URL",
"privateToken": "USER_PRIVATE_TOKEN",
"projectId": "PROJECT_ID",
"configurationId": "CONFIGURATION_ID",
"testRunId": "TEST_RUN_ID",
"testRunName": "TEST_RUN_NAME",
"testRunTags": ["smoke", "nightly"],
"testRunLinks": [
{
"url": "https://gitlab.example.com/group/project/-/jobs/12345",
"title": "CI Job",
"type": "Related"
}
],
"adapterMode": ADAPTER_MODE,
"automaticCreationTestCases": AUTOMATIC_CREATION_TEST_CASES,
"automaticUpdationLinksToTestCases": AUTOMATIC_UPDATION_LINKS_TO_TEST_CASES,
"certValidation": CERT_VALIDATION,
"ignoreParameters": IGNORE_PARAMETERS,
"certValidation": CERT_VALIDATION,
"rerunTestsCount": RERUN_TESTS_COUNT,
"importRealtime": true,
"syncStoragePort": 49152
}
Examples
NOTE: To run tests, you must use the TmsRunner utility.
TmsRunner --runner "/usr/local/share/dotnet/sdk/6.0.302/vstest.console.dll" --testassembly "/tests/MsTest.dll" --tmsUrl=http://localhost:8080 --tmsPrivateToken=Token --tmsProjectId=f5da5bab-380a-4382-b36f-600083fdd795 --tmsConfigurationId=3a14fa45-b54e-4859-9998-cc502d4cc8c6
-tmsAdapterMode=0 --tmsTestRunId=a17269da-bc65-4671-90dd-d3e3da92af80 --tmsTestRunName=Regress --tmsAutomaticCreationTestCases=true --tmsAutomaticUpdationLinksToTestCases=true --tmsCertValidation=true --tmsLabelsOfTestsToRun smoke,regress --tmsIgnoreParameters=true --debug --tmsRerunTestsCount=2
runner- path to vstest.console.dll or vstest.console.exetestassembly- path to dll with testsdebug- enable debug logs
Test run link types
Supported values for testRunLinks[].type (default: Related):
RelatedBlockedByDefectIssueRequirementRepository
Example with CI job URL:
export TMS_TEST_RUN_LINKS='[{"url":"'"$CI_JOB_URL"'","title":"CI Job","type":"Related"}]'
export TMS_TEST_RUN_TAGS='smoke,nightly'
Attributes
Use attributes to specify information about autotest.
Description of attributes:
WorkItemIds- a method that links autotests with manual tests. Receives the array of manual tests' IDsDisplayName- internal autotest name (used in Test IT)ExternalId- unique internal autotest ID (used in Test IT)Title- autotest name specified in the autotest card. If not specified, the name from the displayName method is usedDescription- autotest description specified in the autotest cardLabels- labels listed in the autotest cardTags- tags listed in the autotest cardLinks- links listed in the autotest cardStep- the designation of the step
Description of methods:
Adapter.AddLinks- add links to the autotest result.Adapter.AddAttachments- add attachments to the autotest result.Adapter.AddMessage- add message to the autotest result.
Examples
Simple test
using Tms.Adapter;
using Tms.Adapter.Attributes;
using Tms.Adapter.Models;
using Atr = Tms.Adapter.Attributes;
public class SampleTests {
[Step]
public void CreateProject()
{
Assert.IsTrue(true);
}
[Step]
[Title("Enter project title")]
[Atr.Description("Enter project description")]
public void EnterProject()
{
Assert.IsTrue(true);
}
[Step]
public void CreateSection()
{
Assert.IsTrue(true);
Adapter.AddAttachments("/Users/user/screen.json");
}
[TestMethod]
[WorkItemIds("1523344")]
[ExternalId("all_annotations_test")]
[Title("All Annotations Test Title")]
[DisplayName("All Annotations Test Display Name")]
[Tags("tag01", "tag02")]
[Atr.Description("All Annotations Test Description")]
[Links(url: "https://testit.ru/", LinkType.Related, "TestTitle", "TestDescr")]
[Links(url: "https://testit.ru/", LinkType.Defect)]
public void AllAnnotationsTest()
{
Adapter.AddLinks("https://testit.ru/", "Test 4", "Desc 4", LinkType.Related);
CreateProject();
EnterProject();
CreateSection();
}
}
Parameterized test
using Tms.Adapter.Attributes;
public class ParameterizedTests {
[Parameterized]
[DataRow(MsTest.TestType.Parameter)]
[DataRow(MsTest.TestType.Simple)]
[ExternalId("TestType_{testType}")]
[Title("Title {testType}")]
[DisplayName("Display Name {testType}")]
[TestMethod]
public async Task TestType(TestType testType)
{
Assert.AreEqual(testType, testType);
}
[Parameterized]
[DataRow(1,1,2)]
[DataRow(2,2,4)]
[ExternalId("Sum_{a}_{b}_{c}")]
[Title("Title {a} {b} {c}")]
[DisplayName("Display Name {a} {b} {c}")]
[TestMethod]
public async Task Sum(int a, int b, int c)
{
Assert.AreEqual(c, a + b);
}
}
Contributing
You can help to develop the project. Any contributions are greatly appreciated.
- If you have suggestions for adding or removing projects, feel free to open an issue to discuss it, or create a direct pull request after you edit the README.md file with necessary changes.
- Make sure to check your spelling and grammar.
- Create individual PR for each suggestion.
- Read the Code Of Conduct before posting your first idea as well.
License
Distributed under the Apache-2.0 License. See LICENSE for more information.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.1 is compatible. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
.NETStandard 2.1
- Fody (>= 6.6.4)
- MethodBoundaryAspect.Fody (>= 2.0.148)
- Microsoft.TestPlatform.ObjectModel (>= 17.9.0)
- Newtonsoft.Json (>= 13.0.3)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 3.2.0 | 35 | 8/28/2026 |
| 3.1.0 | 100 | 8/14/2026 |
| 3.0.1 | 87 | 8/12/2026 |
| 3.0.1-TMS-5.8 | 45 | 8/12/2026 |
| 3.0.0 | 106 | 7/22/2026 |
| 3.0.0-TMS-5.8 | 53 | 7/22/2026 |
| 2.2.1-TMS-5.8 | 53 | 7/21/2026 |
| 2.2.0 | 214 | 7/21/2026 |
| 2.2.0-TMS-5.8 | 61 | 7/7/2026 |
| 2.1.2 | 119 | 6/8/2026 |
| 2.1.1 | 110 | 6/8/2026 |
| 2.1.1-TMS-5.7 | 59 | 6/8/2026 |
| 2.1.0 | 120 | 6/5/2026 |
| 2.1.0-TMS-5.7 | 54 | 6/5/2026 |
| 2.0.3 | 311 | 5/13/2026 |
| 2.0.3-TMS-5.7 | 53 | 5/13/2026 |
| 2.0.2 | 110 | 5/5/2026 |
| 2.0.1 | 126 | 4/15/2026 |
| 2.0.1-TMS-5.7 | 59 | 4/15/2026 |
| 2.0.0-TMS-5.7 | 55 | 4/7/2026 |
Loading failed