forked from dotnet/sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathGivenThatTheUserRequestsHelp.cs
More file actions
52 lines (47 loc) · 1.54 KB
/
GivenThatTheUserRequestsHelp.cs
File metadata and controls
52 lines (47 loc) · 1.54 KB
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
47
48
49
50
51
52
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
namespace dotnet.Tests
{
public class GivenThatTheUserRequestsHelp : SdkTest
{
public GivenThatTheUserRequestsHelp(ITestOutputHelper log) : base(log)
{
}
[Theory]
[InlineData("-h")]
[InlineData("add -h")]
[InlineData("add package -h")]
[InlineData("add reference -h")]
[InlineData("build -h")]
[InlineData("clean -h")]
[InlineData("list -h")]
[InlineData("msbuild -h")]
[InlineData("new -h --debug:ephemeral-hive")]
[InlineData("nuget -h")]
[InlineData("pack -h")]
[InlineData("publish -h")]
[InlineData("remove -h")]
[InlineData("restore -h")]
[InlineData("run -h")]
[InlineData("sln -h")]
[InlineData("sln add -h")]
[InlineData("sln list -h")]
[InlineData("sln remove -h")]
[InlineData("store -h")]
[InlineData("test -h")]
public void TheResponseIsNotAnError(string commandLine)
{
var result = new DotnetCommand(Log)
.Execute(commandLine.Split());
result.ExitCode.Should().Be(0);
}
[Theory]
[InlineData("faketool -h")]
public void TheResponseIsAnError(string commandLine)
{
var result = new DotnetCommand(Log)
.Execute(commandLine.Split());
result.ExitCode.Should().Be(1);
}
}
}