diff --git a/NuGet.Config b/NuGet.Config
index 57859c5533..9c189cf33e 100644
--- a/NuGet.Config
+++ b/NuGet.Config
@@ -5,5 +5,6 @@
+
-
\ No newline at end of file
+
diff --git a/tests/OmniSharp.DotNet.Tests/OmniSharp.DotNet.Tests.csproj b/tests/OmniSharp.DotNet.Tests/OmniSharp.DotNet.Tests.csproj
index 2d5f8faf59..768668fd32 100644
--- a/tests/OmniSharp.DotNet.Tests/OmniSharp.DotNet.Tests.csproj
+++ b/tests/OmniSharp.DotNet.Tests/OmniSharp.DotNet.Tests.csproj
@@ -19,8 +19,8 @@
-
-
+
+
diff --git a/tests/OmniSharp.DotNetTest.Tests/GetTestStartInfoFacts.cs b/tests/OmniSharp.DotNetTest.Tests/GetTestStartInfoFacts.cs
index 6ae274534b..3bbf70f72c 100644
--- a/tests/OmniSharp.DotNetTest.Tests/GetTestStartInfoFacts.cs
+++ b/tests/OmniSharp.DotNetTest.Tests/GetTestStartInfoFacts.cs
@@ -25,7 +25,7 @@ await GetDotNetTestStartInfoAsync(
// NUnit does not work with .NET CLI RTM yet. https://github.com/nunit/dotnet-test-nunit/issues/108
// When it does, the NUnitTestProject should be updated and the tests below re-enabled.
- //[Fact]
+ [Fact]
public async Task RunNunitTest()
{
await GetDotNetTestStartInfoAsync(
diff --git a/tests/OmniSharp.DotNetTest.Tests/OmniSharp.DotNetTest.Tests.csproj b/tests/OmniSharp.DotNetTest.Tests/OmniSharp.DotNetTest.Tests.csproj
index 054cb573d9..be3c63bfb8 100644
--- a/tests/OmniSharp.DotNetTest.Tests/OmniSharp.DotNetTest.Tests.csproj
+++ b/tests/OmniSharp.DotNetTest.Tests/OmniSharp.DotNetTest.Tests.csproj
@@ -20,8 +20,8 @@
-
-
+
+
diff --git a/tests/OmniSharp.MSBuild.Tests/GlobalSuppressions.cs b/tests/OmniSharp.MSBuild.Tests/GlobalSuppressions.cs
new file mode 100644
index 0000000000..c4e9174fbd
--- /dev/null
+++ b/tests/OmniSharp.MSBuild.Tests/GlobalSuppressions.cs
@@ -0,0 +1,8 @@
+
+// This file is used by Code Analysis to maintain SuppressMessage
+// attributes that are applied to this project.
+// Project-level suppressions either have no target or are given
+// a specific target and scoped to a namespace, type, member, etc.
+
+[assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Usage", "xUnit1004:Test methods should not be skipped", Justification = "", Scope = "member", Target = "~M:OmniSharp.MSBuild.Tests.WorkspaceInformationTests.ProjectWithSdkProperty~System.Threading.Tasks.Task")]
+
diff --git a/tests/OmniSharp.MSBuild.Tests/OmniSharp.MSBuild.Tests.csproj b/tests/OmniSharp.MSBuild.Tests/OmniSharp.MSBuild.Tests.csproj
index 9e97b973d8..1c64277b1d 100644
--- a/tests/OmniSharp.MSBuild.Tests/OmniSharp.MSBuild.Tests.csproj
+++ b/tests/OmniSharp.MSBuild.Tests/OmniSharp.MSBuild.Tests.csproj
@@ -19,8 +19,8 @@
-
-
+
+
diff --git a/tests/OmniSharp.Roslyn.CSharp.Tests/DiagnosticsV2Facts.cs b/tests/OmniSharp.Roslyn.CSharp.Tests/DiagnosticsV2Facts.cs
index 8209135d17..ff34b4ea6f 100644
--- a/tests/OmniSharp.Roslyn.CSharp.Tests/DiagnosticsV2Facts.cs
+++ b/tests/OmniSharp.Roslyn.CSharp.Tests/DiagnosticsV2Facts.cs
@@ -99,7 +99,7 @@ public async Task EnablesWhenEndPointIsHit(string filename1, string filename2)
var controller = new DiagnosticsService(host.Workspace, forwarder, service);
var response = await controller.Handle(new DiagnosticsRequest());
- Assert.Equal(true, forwarder.IsEnabled);
+ Assert.True(forwarder.IsEnabled);
}
}
}
diff --git a/tests/OmniSharp.Roslyn.CSharp.Tests/OmniSharp.Roslyn.CSharp.Tests.csproj b/tests/OmniSharp.Roslyn.CSharp.Tests/OmniSharp.Roslyn.CSharp.Tests.csproj
index 8bf5985101..2407c05cab 100644
--- a/tests/OmniSharp.Roslyn.CSharp.Tests/OmniSharp.Roslyn.CSharp.Tests.csproj
+++ b/tests/OmniSharp.Roslyn.CSharp.Tests/OmniSharp.Roslyn.CSharp.Tests.csproj
@@ -19,8 +19,8 @@
-
-
+
+
diff --git a/tests/OmniSharp.Roslyn.CSharp.Tests/SignatureHelpFacts.cs b/tests/OmniSharp.Roslyn.CSharp.Tests/SignatureHelpFacts.cs
index ce14024096..ab1da96d8a 100644
--- a/tests/OmniSharp.Roslyn.CSharp.Tests/SignatureHelpFacts.cs
+++ b/tests/OmniSharp.Roslyn.CSharp.Tests/SignatureHelpFacts.cs
@@ -259,7 +259,7 @@ private int Foo(string m, int n)
}";
var actual = await GetSignatureHelp(source);
Assert.Equal(3, actual.Signatures.Count());
- Assert.True(actual.Signatures.ElementAt(actual.ActiveSignature).Documentation.Contains("foo2"));
+ Assert.Contains("foo2", actual.Signatures.ElementAt(actual.ActiveSignature).Documentation);
}
[Fact]
@@ -289,7 +289,7 @@ private int Foo(string m, int n)
}";
var actual = await GetSignatureHelp(source);
Assert.Equal(3, actual.Signatures.Count());
- Assert.True(actual.Signatures.ElementAt(actual.ActiveSignature).Documentation.Contains("foo3"));
+ Assert.Contains("foo3", actual.Signatures.ElementAt(actual.ActiveSignature).Documentation);
}
[Fact]
@@ -319,7 +319,7 @@ private int Foo(string m, int n)
}";
var actual = await GetSignatureHelp(source);
Assert.Equal(3, actual.Signatures.Count());
- Assert.True(actual.Signatures.ElementAt(actual.ActiveSignature).Documentation.Contains("foo1"));
+ Assert.Contains("foo1", actual.Signatures.ElementAt(actual.ActiveSignature).Documentation);
}
[Fact]
@@ -372,7 +372,7 @@ public Program(Program p, int n)
var actual = await GetSignatureHelp(source);
Assert.Equal(3, actual.Signatures.Count());
Assert.Equal(1, actual.ActiveParameter);
- Assert.True(actual.Signatures.ElementAt(actual.ActiveSignature).Documentation.Contains("ctor2"));
+ Assert.Contains("ctor2", actual.Signatures.ElementAt(actual.ActiveSignature).Documentation);
}
[Fact]
diff --git a/tests/OmniSharp.Stdio.Tests/OmniSharp.Stdio.Tests.csproj b/tests/OmniSharp.Stdio.Tests/OmniSharp.Stdio.Tests.csproj
index de2fef1e48..290e12c6aa 100644
--- a/tests/OmniSharp.Stdio.Tests/OmniSharp.Stdio.Tests.csproj
+++ b/tests/OmniSharp.Stdio.Tests/OmniSharp.Stdio.Tests.csproj
@@ -19,8 +19,8 @@
-
-
+
+
diff --git a/tests/OmniSharp.Stdio.Tests/StdioServerFacts.cs b/tests/OmniSharp.Stdio.Tests/StdioServerFacts.cs
index 69af160dd4..f19c61b0d2 100644
--- a/tests/OmniSharp.Stdio.Tests/StdioServerFacts.cs
+++ b/tests/OmniSharp.Stdio.Tests/StdioServerFacts.cs
@@ -106,8 +106,8 @@ public void ServerRepliesWithResponse()
var packet = JsonConvert.DeserializeObject(value);
Assert.Equal(request.Seq, packet.Request_seq);
Assert.Equal(request.Command, packet.Command);
- Assert.Equal(true, packet.Success);
- Assert.Equal(true, packet.Running);
+ Assert.True(packet.Success);
+ Assert.True(packet.Running);
Assert.Null(packet.Message);
}
);
@@ -134,14 +134,14 @@ public void ServerRepliesWithResponseWhenTaskDoesNotReturnAnything()
},
value =>
{
- Assert.True(value.Contains("\"Body\":null"));
+ Assert.Contains("\"Body\":null", value);
// Deserialize is too relaxed...
var packet = JsonConvert.DeserializeObject(value);
Assert.Equal(request.Seq, packet.Request_seq);
Assert.Equal(request.Command, packet.Command);
- Assert.Equal(true, packet.Success);
- Assert.Equal(true, packet.Running);
+ Assert.True(packet.Success);
+ Assert.True(packet.Running);
Assert.Null(packet.Message);
Assert.Null(packet.Body);
}
@@ -172,8 +172,8 @@ public void ServerRepliesWithResponseWhenHandlerFails()
var packet = JsonConvert.DeserializeObject(value);
Assert.Equal(request.Seq, packet.Request_seq);
Assert.Equal(request.Command, packet.Command);
- Assert.Equal(false, packet.Success);
- Assert.Equal(true, packet.Running);
+ Assert.False(packet.Success);
+ Assert.True(packet.Running);
Assert.NotNull(packet.Message);
}
);
@@ -189,4 +189,4 @@ public void ServerRepliesWithResponseWhenHandlerFails()
Assert.Null(writer.Exception);
}
}
-}
\ No newline at end of file
+}
diff --git a/tests/OmniSharp.Tests/GlobalSuppressions.cs b/tests/OmniSharp.Tests/GlobalSuppressions.cs
new file mode 100644
index 0000000000..480acc9bd8
--- /dev/null
+++ b/tests/OmniSharp.Tests/GlobalSuppressions.cs
@@ -0,0 +1,8 @@
+
+// This file is used by Code Analysis to maintain SuppressMessage
+// attributes that are applied to this project.
+// Project-level suppressions either have no target or are given
+// a specific target and scoped to a namespace, type, member, etc.
+
+[assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Usage", "xUnit1004:Test methods should not be skipped", Justification = "", Scope = "member", Target = "~M:OmniSharp.Tests.UpdateBufferFilterFacts.UpdateBuffer_TransientDocumentsDisappearWhenProjectAddsThem~System.Threading.Tasks.Task")]
+
diff --git a/tests/OmniSharp.Tests/MarkupCodeFacts.cs b/tests/OmniSharp.Tests/MarkupCodeFacts.cs
index 5d90534e3e..604465a84b 100644
--- a/tests/OmniSharp.Tests/MarkupCodeFacts.cs
+++ b/tests/OmniSharp.Tests/MarkupCodeFacts.cs
@@ -14,7 +14,7 @@ public void NoMarkupHasNoPositionAndNoSpans()
var markupCode = TestContent.Parse(code);
Assert.Equal("class C { }", markupCode.Code);
- Assert.Equal(false, markupCode.HasPosition);
+ Assert.False(markupCode.HasPosition);
Assert.Throws(() => { var _ = markupCode.Position; });
var spans = markupCode.GetSpans();
@@ -28,7 +28,7 @@ public void PositionAtStartShouldBeZero()
var markupCode = TestContent.Parse(code);
Assert.Equal("class C { }", markupCode.Code);
- Assert.Equal(true, markupCode.HasPosition);
+ Assert.True(markupCode.HasPosition);
Assert.Equal(0, markupCode.Position);
}
@@ -39,7 +39,7 @@ public void PositionAtEndShouldBeSameAsCodeLength()
var markupCode = TestContent.Parse(code);
Assert.Equal("class C { }", markupCode.Code);
- Assert.Equal(true, markupCode.HasPosition);
+ Assert.True(markupCode.HasPosition);
Assert.Equal(markupCode.Code.Length, markupCode.Position);
}
@@ -50,7 +50,7 @@ public void PositionWithInterpolatedString()
var markupCode = TestContent.Parse(code);
Assert.Equal(@"class C { string s = $""Hello""; }", markupCode.Code);
- Assert.Equal(true, markupCode.HasPosition);
+ Assert.True(markupCode.HasPosition);
Assert.Equal(21, markupCode.Position);
}
diff --git a/tests/OmniSharp.Tests/OmniSharp.Tests.csproj b/tests/OmniSharp.Tests/OmniSharp.Tests.csproj
index e102907d55..62a7694710 100644
--- a/tests/OmniSharp.Tests/OmniSharp.Tests.csproj
+++ b/tests/OmniSharp.Tests/OmniSharp.Tests.csproj
@@ -20,8 +20,8 @@
-
-
+
+
diff --git a/tests/OmniSharp.Tests/ZeroBasedIndexConverterFacts.cs b/tests/OmniSharp.Tests/ZeroBasedIndexConverterFacts.cs
index 1e91fdeca3..3f710c77f9 100644
--- a/tests/OmniSharp.Tests/ZeroBasedIndexConverterFacts.cs
+++ b/tests/OmniSharp.Tests/ZeroBasedIndexConverterFacts.cs
@@ -24,8 +24,8 @@ public void ShouldInteractWithEmacsLikeRequests()
var input = JsonConvert.DeserializeObject(output);
- Assert.Equal(input.Line, 0);
- Assert.Equal(input.Column, 0);
+ Assert.Equal(0, input.Line);
+ Assert.Equal(0, input.Column);
}
[Fact]
diff --git a/tests/TestUtility/TestUtility.csproj b/tests/TestUtility/TestUtility.csproj
index 0259f8ac52..f6e7927f5a 100644
--- a/tests/TestUtility/TestUtility.csproj
+++ b/tests/TestUtility/TestUtility.csproj
@@ -23,7 +23,7 @@
-
+