From adb8ecba80e67e269d3f59ca509009b1f7a39c86 Mon Sep 17 00:00:00 2001 From: Cyberboss Date: Sat, 11 Nov 2017 15:17:20 -0500 Subject: [PATCH 1/3] Add missing references to test project --- TGServiceTests/TGServiceTests.csproj | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/TGServiceTests/TGServiceTests.csproj b/TGServiceTests/TGServiceTests.csproj index eb363ef2f3..fa1daa7663 100644 --- a/TGServiceTests/TGServiceTests.csproj +++ b/TGServiceTests/TGServiceTests.csproj @@ -84,6 +84,14 @@ {89191f69-b18e-4b59-b72e-e12f9b6811a0} TGCommandLine + + {394e7643-6b8c-416f-ab18-95ac12648cdc} + TGControlPanel + + + {8956d4c3-bfb9-448e-bf5f-ee7e6f9996f9} + TGInstallerWrapper + {f32eda25-0855-411c-af5e-f0d042917e2d} TGServerService From f0e6f36922c38a7748784586e939fb633ec3cc04 Mon Sep 17 00:00:00 2001 From: Cyberboss Date: Sat, 11 Nov 2017 15:23:57 -0500 Subject: [PATCH 2/3] Disable parallel builds --- appveyor.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/appveyor.yml b/appveyor.yml index 81f2bfc011..2458efe369 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -28,7 +28,7 @@ before_build: - nuget restore TGStationServer3.sln build: project: TGStationServer3.sln - parallel: true + parallel: false verbosity: minimal publish_nuget: true after_build: From cf491cd9470432d37b76f2b98ebf8f4718b4d60b Mon Sep 17 00:00:00 2001 From: Cyberboss Date: Sat, 11 Nov 2017 17:07:20 -0500 Subject: [PATCH 3/3] Add a basic ControlPanel test to reference it for coverage --- .../ControlPanel/TestInstanceSelector.cs | 29 +++++++++++++++++++ TGServiceTests/TGServiceTests.csproj | 2 ++ 2 files changed, 31 insertions(+) create mode 100644 TGServiceTests/ControlPanel/TestInstanceSelector.cs diff --git a/TGServiceTests/ControlPanel/TestInstanceSelector.cs b/TGServiceTests/ControlPanel/TestInstanceSelector.cs new file mode 100644 index 0000000000..626fbe3195 --- /dev/null +++ b/TGServiceTests/ControlPanel/TestInstanceSelector.cs @@ -0,0 +1,29 @@ +using Microsoft.VisualStudio.TestTools.UnitTesting; +using Moq; +using System.Collections.Generic; +using TGServiceInterface; +using TGServiceInterface.Components; + +namespace TGControlPanel.Tests +{ + /// + /// Tests for + /// + [TestClass] + public class TestInstanceSelector + { + /// + /// Test that an can be created without issue + /// + [TestMethod] + public void TestInstatiation() + { + var mockLanding = new Mock(); + mockLanding.Setup(x => x.ListInstances()).Returns(new List()); + var mockInter = new Mock(); + mockInter.Setup(x => x.GetComponent()).Returns(mockLanding.Object); + + new InstanceSelector(mockInter.Object).Dispose(); + } + } +} diff --git a/TGServiceTests/TGServiceTests.csproj b/TGServiceTests/TGServiceTests.csproj index fa1daa7663..870d624bb6 100644 --- a/TGServiceTests/TGServiceTests.csproj +++ b/TGServiceTests/TGServiceTests.csproj @@ -57,11 +57,13 @@ + +