refactor: fix SA1208 (#218)
This commit is contained in:
Родитель
c71e1ea5da
Коммит
644512a17f
|
@ -495,10 +495,6 @@ dotnet_diagnostic.SA1202.severity = suggestion
|
||||||
# 'public' members should come before 'private' members
|
# 'public' members should come before 'private' members
|
||||||
dotnet_diagnostic.SA1203.severity = suggestion
|
dotnet_diagnostic.SA1203.severity = suggestion
|
||||||
|
|
||||||
# https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/SA1208.md
|
|
||||||
# Using directive for '...' should appear before directive for '...'
|
|
||||||
dotnet_diagnostic.SA1208.severity = suggestion
|
|
||||||
|
|
||||||
# https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/SA1210.md
|
# https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/SA1210.md
|
||||||
# Using directives should be ordered alphabetically by the namespaces
|
# Using directives should be ordered alphabetically by the namespaces
|
||||||
dotnet_diagnostic.SA1210.severity = suggestion
|
dotnet_diagnostic.SA1210.severity = suggestion
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
using System.Text.RegularExpressions;
|
|
||||||
|
|
||||||
// transcribed from https://github.com/containers/image/blob/c1a5f92d0ebbf9e0bf187b3353dd400472b388eb/docker/reference/reference.go
|
// transcribed from https://github.com/containers/image/blob/c1a5f92d0ebbf9e0bf187b3353dd400472b388eb/docker/reference/reference.go
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
using PackageUrl;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
using PackageUrl;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Contracts.TypedComponent
|
namespace Microsoft.ComponentDetection.Contracts.TypedComponent
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
using Microsoft.ComponentDetection.Contracts.Internal;
|
using System.Threading.Tasks;
|
||||||
using System.Threading.Tasks;
|
using Microsoft.ComponentDetection.Contracts.Internal;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Maven
|
namespace Microsoft.ComponentDetection.Detectors.Maven
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
using System;
|
||||||
using Microsoft.ComponentDetection.Contracts.Internal;
|
|
||||||
using System;
|
|
||||||
using System.Composition;
|
using System.Composition;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
|
using Microsoft.ComponentDetection.Contracts.Internal;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Maven
|
namespace Microsoft.ComponentDetection.Detectors.Maven
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
using System.Composition;
|
||||||
using System.Composition;
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Maven
|
namespace Microsoft.ComponentDetection.Detectors.Maven
|
||||||
{
|
{
|
||||||
|
|
|
@ -2,13 +2,13 @@
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Composition;
|
using System.Composition;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
|
using System.Text.RegularExpressions;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
using Microsoft.ComponentDetection.Contracts.Internal;
|
using Microsoft.ComponentDetection.Contracts.Internal;
|
||||||
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
||||||
using Newtonsoft.Json.Linq;
|
using Newtonsoft.Json.Linq;
|
||||||
using NuGet.Versioning;
|
using NuGet.Versioning;
|
||||||
using System.Text.RegularExpressions;
|
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Npm
|
namespace Microsoft.ComponentDetection.Detectors.Npm
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
using System;
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Composition;
|
using System.Composition;
|
||||||
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using System.IO;
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
|
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Pip
|
namespace Microsoft.ComponentDetection.Detectors.Pip
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
using System;
|
||||||
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Composition;
|
using System.Composition;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
|
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Pip
|
namespace Microsoft.ComponentDetection.Detectors.Pip
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,11 +1,3 @@
|
||||||
using DotNet.Globbing;
|
|
||||||
using Microsoft.ComponentDetection.Common;
|
|
||||||
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
|
||||||
using Microsoft.ComponentDetection.Common.Telemetry.Records;
|
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
|
||||||
using Microsoft.ComponentDetection.Contracts.BcdeModels;
|
|
||||||
using Microsoft.ComponentDetection.Orchestrator.ArgumentSets;
|
|
||||||
using Newtonsoft.Json;
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Concurrent;
|
using System.Collections.Concurrent;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
@ -15,7 +7,14 @@ using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
using DotNet.Globbing;
|
||||||
|
using Microsoft.ComponentDetection.Common;
|
||||||
|
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
||||||
|
using Microsoft.ComponentDetection.Common.Telemetry.Records;
|
||||||
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
|
using Microsoft.ComponentDetection.Contracts.BcdeModels;
|
||||||
|
using Microsoft.ComponentDetection.Orchestrator.ArgumentSets;
|
||||||
|
using Newtonsoft.Json;
|
||||||
using static System.Environment;
|
using static System.Environment;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Orchestrator.Services
|
namespace Microsoft.ComponentDetection.Orchestrator.Services
|
||||||
|
|
|
@ -3,6 +3,7 @@ using System.Collections.Generic;
|
||||||
using System.Composition;
|
using System.Composition;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using Microsoft.ComponentDetection.Common;
|
using Microsoft.ComponentDetection.Common;
|
||||||
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
||||||
using Microsoft.ComponentDetection.Common.Telemetry.Records;
|
using Microsoft.ComponentDetection.Common.Telemetry.Records;
|
||||||
|
@ -10,7 +11,6 @@ using Microsoft.ComponentDetection.Contracts;
|
||||||
using Microsoft.ComponentDetection.Contracts.BcdeModels;
|
using Microsoft.ComponentDetection.Contracts.BcdeModels;
|
||||||
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
||||||
using Microsoft.ComponentDetection.Orchestrator.ArgumentSets;
|
using Microsoft.ComponentDetection.Orchestrator.ArgumentSets;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Orchestrator.Services.GraphTranslation
|
namespace Microsoft.ComponentDetection.Orchestrator.Services.GraphTranslation
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using System;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
using System;
|
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Common.Tests
|
namespace Microsoft.ComponentDetection.Common.Tests
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,15 +1,15 @@
|
||||||
using FluentAssertions;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using FluentAssertions;
|
||||||
using Microsoft.ComponentDetection.Common;
|
using Microsoft.ComponentDetection.Common;
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
using Microsoft.ComponentDetection.Contracts.Internal;
|
using Microsoft.ComponentDetection.Contracts.Internal;
|
||||||
using Microsoft.ComponentDetection.Detectors.Maven;
|
using Microsoft.ComponentDetection.Detectors.Maven;
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
using Moq;
|
using Moq;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Tests
|
namespace Microsoft.ComponentDetection.Detectors.Tests
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using System;
|
||||||
using System;
|
|
||||||
using static Microsoft.ComponentDetection.Detectors.Maven.MavenParsingUtilities;
|
|
||||||
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
|
||||||
using Microsoft.ComponentDetection.Contracts.BcdeModels;
|
using Microsoft.ComponentDetection.Contracts.BcdeModels;
|
||||||
|
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
using static Microsoft.ComponentDetection.Detectors.Maven.MavenParsingUtilities;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Tests
|
namespace Microsoft.ComponentDetection.Detectors.Tests
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
|
||||||
using Microsoft.ComponentDetection.TestsUtilities;
|
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
|
@ -9,8 +5,12 @@ using System.Linq;
|
||||||
using System.Security.Cryptography;
|
using System.Security.Cryptography;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
||||||
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
||||||
using Microsoft.ComponentDetection.Detectors.Spdx;
|
using Microsoft.ComponentDetection.Detectors.Spdx;
|
||||||
|
using Microsoft.ComponentDetection.TestsUtilities;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Tests
|
namespace Microsoft.ComponentDetection.Detectors.Tests
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
using Microsoft.ComponentDetection.Contracts.TypedComponent;
|
||||||
using Microsoft.ComponentDetection.Detectors.Vcpkg;
|
using Microsoft.ComponentDetection.Detectors.Vcpkg;
|
||||||
using Microsoft.ComponentDetection.TestsUtilities;
|
using Microsoft.ComponentDetection.TestsUtilities;
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.Detectors.Tests
|
namespace Microsoft.ComponentDetection.Detectors.Tests
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
using Moq;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
@ -8,6 +7,7 @@ using Microsoft.ComponentDetection.Common;
|
||||||
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
using Microsoft.ComponentDetection.Common.DependencyGraph;
|
||||||
using Microsoft.ComponentDetection.Contracts;
|
using Microsoft.ComponentDetection.Contracts;
|
||||||
using Microsoft.ComponentDetection.Contracts.Internal;
|
using Microsoft.ComponentDetection.Contracts.Internal;
|
||||||
|
using Moq;
|
||||||
|
|
||||||
namespace Microsoft.ComponentDetection.TestsUtilities
|
namespace Microsoft.ComponentDetection.TestsUtilities
|
||||||
{
|
{
|
||||||
|
|
Загрузка…
Ссылка в новой задаче