forked from microsoft/vstest
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ShowDeprecateDotnetVStestMessageArgumentProcessorTests.cs
46 lines (39 loc) · 2.38 KB
/
ShowDeprecateDotnetVStestMessageArgumentProcessorTests.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
using Microsoft.VisualStudio.TestPlatform.CommandLine.Processors;
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace vstest.console.UnitTests.Processors;
[TestClass]
[TestCategory("Windows-Review")]
public class ShowDeprecateDotnetVStestMessageArgumentProcessorTests
{
[TestMethod]
public void ShowDeprecateDotnetVStestMessageProcessorCommandName()
{
Assert.AreEqual("/ShowDeprecateDotnetVSTestMessage", ShowDeprecateDotnetVStestMessageArgumentProcessor.CommandName);
}
[TestMethod]
public void ShowDeprecateDotnetVStestMessageProcessorCapabilities()
{
ShowDeprecateDotnetVStestMessageProcessorCapabilities showDeprecateDotnetVStestMessageProcessorCapabilities = new();
Assert.IsNull(showDeprecateDotnetVStestMessageProcessorCapabilities.HelpContentResourceName);
Assert.IsFalse(showDeprecateDotnetVStestMessageProcessorCapabilities.IsAction);
Assert.IsFalse(showDeprecateDotnetVStestMessageProcessorCapabilities.AllowMultiple);
Assert.AreEqual(ArgumentProcessorPriority.CliRunSettings, showDeprecateDotnetVStestMessageProcessorCapabilities.Priority);
Assert.AreEqual(HelpContentPriority.None, showDeprecateDotnetVStestMessageProcessorCapabilities.HelpPriority);
}
[TestMethod]
public void ShowDeprecateDotnetVStestMessageArgumentProcessorReturnsCorrectTypes()
{
ShowDeprecateDotnetVStestMessageArgumentProcessor showDeprecateDotnetVStestMessageArgumentProcessor = new();
Assert.IsInstanceOfType(showDeprecateDotnetVStestMessageArgumentProcessor.Executor!.Value, typeof(ShowDeprecateDotnetVStestMessageProcessorExecutor));
Assert.IsInstanceOfType(showDeprecateDotnetVStestMessageArgumentProcessor.Metadata!.Value, typeof(ShowDeprecateDotnetVStestMessageProcessorCapabilities));
}
[TestMethod]
public void ShowDeprecateDotnetVStestMessageProcessorExecutor_Succeded()
{
ShowDeprecateDotnetVStestMessageProcessorExecutor showDeprecateDotnetVStestMessageProcessorExecutor = new();
showDeprecateDotnetVStestMessageProcessorExecutor.Initialize("we will ignore the param");
Assert.AreEqual(ArgumentProcessorResult.Success, showDeprecateDotnetVStestMessageProcessorExecutor.Execute());
}
}