diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3f6f21ccf..aff727642 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,15 +10,16 @@ jobs: name: Build runs-on: windows-latest steps: - - name: Set up JDK 11 - uses: actions/setup-java@v1 + - name: Set up JDK 17 + uses: actions/setup-java@v3 with: - java-version: 1.11 - - uses: actions/checkout@v2 + java-version: 17 + distribution: 'zulu' # Alternative distribution options are available. + - uses: actions/checkout@v3 with: fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis - name: Cache SonarCloud packages - uses: actions/cache@v1 + uses: actions/cache@v3 with: path: ~\sonar\cache key: ${{ runner.os }}-sonar @@ -36,13 +37,19 @@ jobs: run: | New-Item -Path .\.sonar\scanner -ItemType Directory dotnet tool update dotnet-sonarscanner --tool-path .\.sonar\scanner + - name: Install Code Coverage + shell: powershell + run: | + dotnet tool install --global dotnet-coverage - name: Build and analyze env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} shell: powershell run: | - .\.sonar\scanner\dotnet-sonarscanner begin /k:"k3ldar_.NetCorePluginManager" /o:"pluginmanager" /d:sonar.login="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io" + .\.sonar\scanner\dotnet-sonarscanner begin /k:"k3ldar_.NetCorePluginManager" /o:"pluginmanager" /d:sonar.login="${{ secrets.SONAR_TOKEN }}" /d:sonar.cs.vscoveragexml.reportsPaths=coverage.xml /d:sonar.host.url="https://sonarcloud.io" dotnet restore ./AspNetCore.PluginManager.Solution.sln dotnet build ./AspNetCore.PluginManager.Solution.sln --configuration Release + dotnet test --collect "Code Coverage" + dotnet-coverage collect "dotnet test ./AspNetCore.PluginManager.Solution.sln" -f xml -o "coverage.xml" .\.sonar\scanner\dotnet-sonarscanner end /d:sonar.login="${{ secrets.SONAR_TOKEN }}" diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 732dc9744..13677b545 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -1,14 +1,3 @@ -# For most projects, this workflow file will not need changing; you simply need -# to commit it to your repository. -# -# You may wish to alter this file to override the set of languages analyzed, -# or to provide custom queries or build logic. -# -# ******** NOTE ******** -# We have attempted to detect the languages in your repository. Please check -# the `language` matrix defined below to confirm you have the correct set of -# supported CodeQL languages. -# name: "CodeQL" on: diff --git a/AspNetCore.PluginManager.Solution.sln b/AspNetCore.PluginManager.Solution.sln index e3863081b..73bd6af46 100644 --- a/AspNetCore.PluginManager.Solution.sln +++ b/AspNetCore.PluginManager.Solution.sln @@ -72,8 +72,6 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{9D6C1367-C141-4577-8E9C-5710C9D5E516}" ProjectSection(SolutionItems) = preProject .editorconfig = .editorconfig - appveyor.yml = appveyor.yml - azure-pipelines.yml = azure-pipelines.yml Directory.Build.props = Directory.Build.props README.md = README.md ReleaseNotes.txt = ReleaseNotes.txt @@ -111,6 +109,16 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PluginManager.DAL.TextFiles EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Resources.Plugin", "Plugins\Resources.Plugin\Resources.Plugin.csproj", "{33E06D80-EEED-491E-A212-7C5E6688A37D}" EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".github", ".github", "{0B6CC20A-FE83-4CC7-A836-06CE25C5F24C}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{30CA931F-8150-451B-8720-11D53C7C9749}" + ProjectSection(SolutionItems) = preProject + .github\workflows\build.yml = .github\workflows\build.yml + .github\workflows\codeql-analysis.yml = .github\workflows\codeql-analysis.yml + EndProjectSection +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "ISSUE_TEMPLATE", "ISSUE_TEMPLATE", "{054AB9E6-B61B-416E-9680-8F470C38D767}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -304,6 +312,9 @@ Global {615AE0C8-2986-49AB-9B84-139E252CCB59} = {8522A683-113C-49D8-BA64-E6677D72A5E9} {59B9833B-8752-4257-AB07-244555F71E96} = {19AFBC9B-7D1B-4405-871F-00763C364C86} {2CA6425F-5474-43CC-AC87-47A4D49A8ADA} = {19AFBC9B-7D1B-4405-871F-00763C364C86} + {0B6CC20A-FE83-4CC7-A836-06CE25C5F24C} = {9D6C1367-C141-4577-8E9C-5710C9D5E516} + {30CA931F-8150-451B-8720-11D53C7C9749} = {0B6CC20A-FE83-4CC7-A836-06CE25C5F24C} + {054AB9E6-B61B-416E-9680-8F470C38D767} = {0B6CC20A-FE83-4CC7-A836-06CE25C5F24C} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {144AC182-32DC-41B2-9617-BBB390D27A65} diff --git a/Plugins/HelpDesk.Plugin/Classes/ImportEmailIntoHelpdeskThread.cs b/Plugins/HelpDesk.Plugin/Classes/ImportEmailIntoHelpdeskThread.cs index 2e84da257..f885e6586 100644 --- a/Plugins/HelpDesk.Plugin/Classes/ImportEmailIntoHelpdeskThread.cs +++ b/Plugins/HelpDesk.Plugin/Classes/ImportEmailIntoHelpdeskThread.cs @@ -166,6 +166,15 @@ private void RetrieveEmailsFromPop3Server(List messages) string password = Environment.GetEnvironmentVariable("EmailUserPassword"); string port = Environment.GetEnvironmentVariable("EmailPop3Port"); + if (String.IsNullOrEmpty(pop3Server) || String.IsNullOrEmpty(userName) || String.IsNullOrEmpty(password) || String.IsNullOrEmpty(port)) + { + _logger.AddToLog(PluginManager.LogLevel.Error, "Environment variables not setup for email"); + pop3Server = String.Empty; + userName = String.Empty; + password = String.Empty; + port = String.Empty; + } + using IPop3Client popClient = _pop3ClientFactory.Create(); popClient.Initialize(pop3Server, userName, password, ushort.Parse(port)); diff --git a/Tests/AspNetCore.PluginManager.Tests/AspNetCore.PluginManager.Tests.csproj b/Tests/AspNetCore.PluginManager.Tests/AspNetCore.PluginManager.Tests.csproj index f99aec87c..834e4afe7 100644 --- a/Tests/AspNetCore.PluginManager.Tests/AspNetCore.PluginManager.Tests.csproj +++ b/Tests/AspNetCore.PluginManager.Tests/AspNetCore.PluginManager.Tests.csproj @@ -34,6 +34,10 @@ $(AssemblyOriginatorKeyFile) + + False + + diff --git a/Tests/AspNetCore.PluginManager.Tests/Documentation/DocumentTests.cs b/Tests/AspNetCore.PluginManager.Tests/Documentation/DocumentTests.cs index 37c8c69d6..d1c84389c 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Documentation/DocumentTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Documentation/DocumentTests.cs @@ -47,7 +47,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.DocumentationTests { [TestClass] [ExcludeFromCodeCoverage] - public sealed class DocumentTests : BaseDocumentTests + [DoNotParallelize] + public sealed class DocumentTests : BaseDocumentTests { [TestInitialize] public void Setup() diff --git a/Tests/AspNetCore.PluginManager.Tests/Minification/MinifyTestBase.cs b/Tests/AspNetCore.PluginManager.Tests/Minification/MinifyTestBase.cs index fa635818f..4fc2d173b 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Minification/MinifyTestBase.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Minification/MinifyTestBase.cs @@ -33,13 +33,14 @@ namespace AspNetCore.PluginManager.Tests { - public class MinifyTestBase + [ExcludeFromCodeCoverage] + [DoNotParallelize] + public class MinifyTestBase { [System.Diagnostics.CodeAnalysis.SuppressMessage("Design", "CA1051:Do not declare visible instance fields", Justification = "It's just a test man, innit!")] protected IMinificationEngine _minifyFileContents; [TestInitialize] - [ExcludeFromCodeCoverage] public void InitialiseTest() { _minifyFileContents = new MinificationEngine(); diff --git a/Tests/AspNetCore.PluginManager.Tests/PluginManager/RouteLoadTimeMiddlewareTests.cs b/Tests/AspNetCore.PluginManager.Tests/PluginManager/RouteLoadTimeMiddlewareTests.cs index dfb968bff..ff591f00b 100644 --- a/Tests/AspNetCore.PluginManager.Tests/PluginManager/RouteLoadTimeMiddlewareTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/PluginManager/RouteLoadTimeMiddlewareTests.cs @@ -42,7 +42,8 @@ namespace AspNetCore.PluginManager.Tests.AspNetCore.PluginManager { [TestClass] [ExcludeFromCodeCoverage] - public class RouteLoadTimeMiddlewareTests : GenericBaseClass + [DoNotParallelize] + public class RouteLoadTimeMiddlewareTests : GenericBaseClass { private const string TestCategoryName = "AspNetCore Plugin Manager Tests"; private const string MiddlewareCategoryName = "Middleware"; diff --git a/Tests/AspNetCore.PluginManager.Tests/PluginManager/SystemAdminMenuTests.cs b/Tests/AspNetCore.PluginManager.Tests/PluginManager/SystemAdminMenuTests.cs index 601441f1f..5f33c97dc 100644 --- a/Tests/AspNetCore.PluginManager.Tests/PluginManager/SystemAdminMenuTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/PluginManager/SystemAdminMenuTests.cs @@ -49,7 +49,8 @@ namespace AspNetCore.PluginManager.Tests.AspNetCore.PluginManager { [TestClass] [ExcludeFromCodeCoverage] - public class SystemAdminMenuTests : GenericBaseClass + [DoNotParallelize] + public class SystemAdminMenuTests : GenericBaseClass { private const string TestCategoryName = "AspNetCore Plugin Manager Tests"; private const string SystemAdminCategoryName = "System Admin Menu"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/BadEggTests/BadEggTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/BadEggTests/BadEggTests.cs index 66183a4ac..94f41cce1 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/BadEggTests/BadEggTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/BadEggTests/BadEggTests.cs @@ -53,7 +53,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.BadEggTests { [TestClass] [ExcludeFromCodeCoverage] - public class BadEggTests : BaseMiddlewareTests + [DoNotParallelize] + public class BadEggTests : BaseMiddlewareTests { [TestInitialize] public void InitialiseBadEggTests() diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/BadEggTests/ValidateConnectionsTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/BadEggTests/ValidateConnectionsTests.cs index 349875430..517aa4a35 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/BadEggTests/ValidateConnectionsTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/BadEggTests/ValidateConnectionsTests.cs @@ -44,7 +44,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.BadEggTests { [TestClass] [ExcludeFromCodeCoverage] - public class ValidateConnectionsTests + [DoNotParallelize] + public class ValidateConnectionsTests { private const string TestCategoryName = "BadEgg"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DefaultDynamicContentProviderTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DefaultDynamicContentProviderTests.cs index 368ffa747..a9ecb8dce 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DefaultDynamicContentProviderTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DefaultDynamicContentProviderTests.cs @@ -46,7 +46,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.DynamicContentTests { [TestClass] [ExcludeFromCodeCoverage] - public class DefaultDynamicContentProviderTests : GenericBaseClass + [DoNotParallelize] + public class DefaultDynamicContentProviderTests : GenericBaseClass { private const string TestCategoryName = "Dynamic Content"; private const string HtmlTemplateAssemblyQualifiedName = "DynamicContent.Plugin.Templates.HtmlTextTemplate, DynamicContent.Plugin"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DynamicContentControllerTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DynamicContentControllerTests.cs index d85afca07..a107ffb75 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DynamicContentControllerTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DynamicContentControllerTests.cs @@ -62,8 +62,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.DynamicContentTests { [TestClass] [ExcludeFromCodeCoverage] - - public class DynamicContentControllerTests : BaseControllerTests + [DoNotParallelize] + public class DynamicContentControllerTests : BaseControllerTests { #region Private Members diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DynamicContentThreadManagerTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DynamicContentThreadManagerTests.cs index 401fb78b7..7b1908f11 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DynamicContentThreadManagerTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/DynamicContent/DynamicContentThreadManagerTests.cs @@ -48,7 +48,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.DynamicContentTests { [TestClass] [ExcludeFromCodeCoverage] - public class DynamicContentThreadManagerTests : GenericBaseClass + [DoNotParallelize] + public class DynamicContentThreadManagerTests : GenericBaseClass { private const string TestCategoryName = "Dynamic Content"; private string _currentTestPath = null; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/HelpdeskTests/ImportEmailIntoHelpdeskTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/HelpdeskTests/ImportEmailIntoHelpdeskTests.cs index 6a20853bc..d60da4bba 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/HelpdeskTests/ImportEmailIntoHelpdeskTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/HelpdeskTests/ImportEmailIntoHelpdeskTests.cs @@ -46,8 +46,18 @@ namespace AspNetCore.PluginManager.Tests.Plugins.HelpdeskTests { [TestClass] [ExcludeFromCodeCoverage] + [DoNotParallelize] public class ImportEmailIntoHelpdeskTests { + [TestInitialize] + public void InitialiseTests() + { + Environment.SetEnvironmentVariable("EmailPop3ServerName", "test.server.com"); + Environment.SetEnvironmentVariable("EmailUserName", "myemail.test.server.com"); + Environment.SetEnvironmentVariable("EmailUserPassword", "asdfasdfasdf"); + Environment.SetEnvironmentVariable("EmailPop3Port", "634"); + } + [TestMethod] [ExpectedException(typeof(ArgumentNullException))] public void Construct_InvalidParameter_HelpdeskProviderNull_Throws_ArgumentNullException() diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/ImageManagerTests/DefaultImageProviderTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/ImageManagerTests/DefaultImageProviderTests.cs index 3538c62ca..fcd70be84 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/ImageManagerTests/DefaultImageProviderTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/ImageManagerTests/DefaultImageProviderTests.cs @@ -46,7 +46,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.ImageManagerTests { [TestClass] [ExcludeFromCodeCoverage] - public class DefaultImageProviderTests : GenericBaseClass + [DoNotParallelize] + public class DefaultImageProviderTests : GenericBaseClass { private const string ImageManagerTestsCategory = "Image Manager Tests"; private const string DemoWebsiteImagePath = "..\\..\\..\\..\\..\\..\\.NetCorePluginManager\\Demo\\NetCorePluginDemoWebsite\\wwwroot\\images"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/ImageManagerTests/ImageManagerControllerTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/ImageManagerTests/ImageManagerControllerTests.cs index bd92e58be..74f95a54e 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/ImageManagerTests/ImageManagerControllerTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/ImageManagerTests/ImageManagerControllerTests.cs @@ -57,7 +57,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.ImageManagerTests { [TestClass] [ExcludeFromCodeCoverage] - public class ImageManagerControllerTests : BaseControllerTests + [DoNotParallelize] + public class ImageManagerControllerTests : BaseControllerTests { private const string TestCategoryName = "Image Manager Tests"; private const string ExpectedResponseWithNoListener = "{\"GroupName\":\"Group\",\"SubgroupName\":\"test subgrouP\",\"ShowSubgroup\":true,\"AdditionalDataName\":null,\"AdditionalData\":null,\"AdditionalDataMandatory\":false}"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/LoginTests/LoginControllerTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/LoginTests/LoginControllerTests.cs index 64d9e2168..08f1a0c18 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/LoginTests/LoginControllerTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/LoginTests/LoginControllerTests.cs @@ -58,7 +58,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.LoginTests { [TestClass] [ExcludeFromCodeCoverage] - public class LoginControllerTests : BaseControllerTests + [DoNotParallelize] + public class LoginControllerTests : BaseControllerTests { private const string TestCategoryName = "Login Plugin"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/LoginTests/LoginMiddlewareTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/LoginTests/LoginMiddlewareTests.cs index b3c577459..3759617e2 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/LoginTests/LoginMiddlewareTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/LoginTests/LoginMiddlewareTests.cs @@ -47,7 +47,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.LoginTests { [TestClass] [ExcludeFromCodeCoverage] - public class LoginMiddlewareTests : BaseMiddlewareTests + [DoNotParallelize] + public class LoginMiddlewareTests : BaseMiddlewareTests { private const string TestCategoryName = "Login"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/MemoryCacheTests/MemoryCacheMenuTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/MemoryCacheTests/MemoryCacheMenuTests.cs index 7b968b6c1..ba8721c02 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/MemoryCacheTests/MemoryCacheMenuTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/MemoryCacheTests/MemoryCacheMenuTests.cs @@ -43,7 +43,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.MemoryCacheTests { [TestClass] [ExcludeFromCodeCoverage] - public class DynamicContentMenuTests + [DoNotParallelize] + public class DynamicContentMenuTests { private const string TestCategoryName = "Memory Cache Plugin"; private const string SystemAdminCategoryName = "System Admin"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/DefaultSearchProviderTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/DefaultSearchProviderTests.cs index 2a0f543f9..c243fc040 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/DefaultSearchProviderTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/DefaultSearchProviderTests.cs @@ -50,7 +50,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SearchTests { [TestClass] [ExcludeFromCodeCoverage] - public class DefaultSearchProviderTests : MockBasePlugin + [DoNotParallelize] + public class DefaultSearchProviderTests : MockBasePlugin { [TestInitialize] public void InitializeSearchTests() diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/KeywordSearchTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/KeywordSearchTests.cs index 593f7262b..cd21036a8 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/KeywordSearchTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/KeywordSearchTests.cs @@ -52,6 +52,7 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SearchTests { [TestClass] [ExcludeFromCodeCoverage] + [DoNotParallelize] public sealed class KeywordSearchTests : MockBasePlugin { private const int _searchClassCount = 4; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/SearchControllerTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/SearchControllerTests.cs index b81093dd2..5eaf09d9f 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/SearchControllerTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SearchTests/SearchControllerTests.cs @@ -49,7 +49,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SearchTests { [TestClass] [ExcludeFromCodeCoverage] - public class SearchControllerTests : MockBasePlugin + [DoNotParallelize] + public class SearchControllerTests : MockBasePlugin { [TestInitialize] public void InitializeSearchTests() diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SmokeTestTests/WebSmokeTestTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SmokeTestTests/WebSmokeTestTests.cs index b63b76e21..b52f7af47 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SmokeTestTests/WebSmokeTestTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SmokeTestTests/WebSmokeTestTests.cs @@ -58,7 +58,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SmokeTestTests { [TestClass] [ExcludeFromCodeCoverage] - public class WebSmokeTestTests : BaseMiddlewareTests + [DoNotParallelize] + public class WebSmokeTestTests : BaseMiddlewareTests { private string EncryptionKey; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SpiderTests/SpiderControllerTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SpiderTests/SpiderControllerTests.cs index a122bb7bb..a26ca9d98 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SpiderTests/SpiderControllerTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SpiderTests/SpiderControllerTests.cs @@ -50,7 +50,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SpiderTests { [TestClass] [ExcludeFromCodeCoverage] - public sealed class SpiderControllerTests : BaseControllerTests + [DoNotParallelize] + public sealed class SpiderControllerTests : BaseControllerTests { [TestInitialize] public void InitializeSpiderControllerTests() diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SpiderTests/SpiderMiddlewareTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SpiderTests/SpiderMiddlewareTests.cs index 34142a3e4..21171a3e2 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SpiderTests/SpiderMiddlewareTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SpiderTests/SpiderMiddlewareTests.cs @@ -53,7 +53,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SpiderTests { [TestClass] [ExcludeFromCodeCoverage] - public class SpiderMiddlewareTests : BaseMiddlewareTests + [DoNotParallelize] + public class SpiderMiddlewareTests : BaseMiddlewareTests { [TestInitialize] public void InitializeTest() diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SubdomainTests/SubdomainMiddlewareTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SubdomainTests/SubdomainMiddlewareTests.cs index 9f8beee98..04d5dd044 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SubdomainTests/SubdomainMiddlewareTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SubdomainTests/SubdomainMiddlewareTests.cs @@ -52,7 +52,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SubdomainTests { [TestClass] [ExcludeFromCodeCoverage] - public class SubdomainMiddlewareTests : BaseMiddlewareTests + [DoNotParallelize] + public class SubdomainMiddlewareTests : BaseMiddlewareTests { #region Constants diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SystemAdminTests/PluginInitialisationTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SystemAdminTests/PluginInitialisationTests.cs index 0bb821910..090bf0891 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SystemAdminTests/PluginInitialisationTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SystemAdminTests/PluginInitialisationTests.cs @@ -50,7 +50,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SystemAdminTests { [TestClass] [ExcludeFromCodeCoverage] - public class PluginInitialisationTests + [DoNotParallelize] + public class PluginInitialisationTests { private const string TestsCategoryName = "System Admin"; diff --git a/Tests/AspNetCore.PluginManager.Tests/Plugins/SystemAdminTests/SystemAdminHelperTests.cs b/Tests/AspNetCore.PluginManager.Tests/Plugins/SystemAdminTests/SystemAdminHelperTests.cs index c119aab17..b8653cf7a 100644 --- a/Tests/AspNetCore.PluginManager.Tests/Plugins/SystemAdminTests/SystemAdminHelperTests.cs +++ b/Tests/AspNetCore.PluginManager.Tests/Plugins/SystemAdminTests/SystemAdminHelperTests.cs @@ -43,7 +43,8 @@ namespace AspNetCore.PluginManager.Tests.Plugins.SystemAdminTests { [TestClass] [ExcludeFromCodeCoverage] - public class SystemAdminHelperTests : GenericBaseClass + [DoNotParallelize] + public class SystemAdminHelperTests : GenericBaseClass { private const string TestsCategory = "SystemAdmin Tests"; diff --git a/Tests/PluginManager.DAL.TextFiles.Tests/Providers/DownloadProviderTests.cs b/Tests/PluginManager.DAL.TextFiles.Tests/Providers/DownloadProviderTests.cs index 28ef516da..cf4c1bcde 100644 --- a/Tests/PluginManager.DAL.TextFiles.Tests/Providers/DownloadProviderTests.cs +++ b/Tests/PluginManager.DAL.TextFiles.Tests/Providers/DownloadProviderTests.cs @@ -42,7 +42,8 @@ namespace PluginManager.DAL.TextFiles.Tests.Providers { [TestClass] [ExcludeFromCodeCoverage] - public class DownloadProviderTests : BaseProviderTests + [DoNotParallelize] + public class DownloadProviderTests : BaseProviderTests { [TestInitialize] public void Setup() diff --git a/Tests/PluginManager.DAL.TextFiles.Tests/Providers/DynamicContentProviderTests.cs b/Tests/PluginManager.DAL.TextFiles.Tests/Providers/DynamicContentProviderTests.cs index bf0cf31cd..ff5d3b0b5 100644 --- a/Tests/PluginManager.DAL.TextFiles.Tests/Providers/DynamicContentProviderTests.cs +++ b/Tests/PluginManager.DAL.TextFiles.Tests/Providers/DynamicContentProviderTests.cs @@ -47,7 +47,8 @@ namespace PluginManager.DAL.TextFiles.Tests.Providers { [TestClass] [ExcludeFromCodeCoverage] - public class DynamicContentProviderTests : BaseProviderTests + [DoNotParallelize] + public class DynamicContentProviderTests : BaseProviderTests { [TestInitialize] public void Setup() diff --git a/Tests/PluginManager.DAL.TextFiles.Tests/Providers/HelpdeskProviderTests.cs b/Tests/PluginManager.DAL.TextFiles.Tests/Providers/HelpdeskProviderTests.cs index 842d94393..dc6af8269 100644 --- a/Tests/PluginManager.DAL.TextFiles.Tests/Providers/HelpdeskProviderTests.cs +++ b/Tests/PluginManager.DAL.TextFiles.Tests/Providers/HelpdeskProviderTests.cs @@ -37,11 +37,14 @@ using SimpleDB; using PluginManager.Tests.Mocks; using Shared.Classes; +using System.Diagnostics.CodeAnalysis; namespace PluginManager.DAL.TextFiles.Tests.Providers { [TestClass] - public class HelpdeskProviderTests : BaseProviderTests + [ExcludeFromCodeCoverage] + [DoNotParallelize] + public class HelpdeskProviderTests : BaseProviderTests { [TestInitialize] public void Setup() diff --git a/Tests/PluginManager.DAL.TextFiles.Tests/Providers/ResourceProviderTests.cs b/Tests/PluginManager.DAL.TextFiles.Tests/Providers/ResourceProviderTests.cs index f6852bfb5..504d6352f 100644 --- a/Tests/PluginManager.DAL.TextFiles.Tests/Providers/ResourceProviderTests.cs +++ b/Tests/PluginManager.DAL.TextFiles.Tests/Providers/ResourceProviderTests.cs @@ -51,6 +51,7 @@ namespace PluginManager.DAL.TextFiles.Tests.Providers { [TestClass] [ExcludeFromCodeCoverage] + [DoNotParallelize] public class ResourceProviderTests : BaseProviderTests { [TestInitialize] diff --git a/Tests/PluginManager.Tests/DefaultLoggerTests.cs b/Tests/PluginManager.Tests/DefaultLoggerTests.cs index a16f672a5..35bb1c5e7 100644 --- a/Tests/PluginManager.Tests/DefaultLoggerTests.cs +++ b/Tests/PluginManager.Tests/DefaultLoggerTests.cs @@ -36,7 +36,8 @@ namespace PluginManager.Tests { [TestClass] [ExcludeFromCodeCoverage] - public class DefaultLoggerTests + [DoNotParallelize] + public class DefaultLoggerTests { private TestTraceListener _traceListner; diff --git a/Tests/PluginManager.Tests/PluginHelperServiceTests.cs b/Tests/PluginManager.Tests/PluginHelperServiceTests.cs index 0bb099e88..c011adae3 100644 --- a/Tests/PluginManager.Tests/PluginHelperServiceTests.cs +++ b/Tests/PluginManager.Tests/PluginHelperServiceTests.cs @@ -37,7 +37,8 @@ namespace PluginManager.Tests { [TestClass] [ExcludeFromCodeCoverage] - public class PluginHelperServiceTests + [DoNotParallelize] + public class PluginHelperServiceTests { #region Private Members diff --git a/Tests/PluginManager.Tests/PluginManagerTests.cs b/Tests/PluginManager.Tests/PluginManagerTests.cs index 5e31da670..8b4d97b88 100644 --- a/Tests/PluginManager.Tests/PluginManagerTests.cs +++ b/Tests/PluginManager.Tests/PluginManagerTests.cs @@ -43,7 +43,8 @@ namespace PluginManager.Tests { [TestClass] [ExcludeFromCodeCoverage] - public class PluginManagerTests + [DoNotParallelize] + public class PluginManagerTests { #if DEBUG private const string Build = "Debug"; diff --git a/Tests/test.runsettings b/Tests/test.runsettings index 799588add..8dfb9f8ad 100644 --- a/Tests/test.runsettings +++ b/Tests/test.runsettings @@ -8,7 +8,7 @@ - 60000 + 10000