From 9f294bb4ae5a70a2701866ce884bf8dbf3f545ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Amaury=20Lev=C3=A9?= Date: Wed, 26 Jul 2017 12:11:03 +0200 Subject: [PATCH 1/4] Rule S3717: Track use of 'NotImplementedException' --- ...16-0DCA-4B0F-A0DC-9075E75A676F}-S3717.json | 30 +++ ...51-38C2-4B5D-A6B1-F265A428A673}-S3717.json | 56 ++++++ ...5A-4B65-4C80-B834-9A7773750666}-S3717.json | 17 ++ ...4D-BC4D-4BBB-A478-CAF2D04520E1}-S3717.json | 173 ++++++++++++++++++ ...90-37F0-48D3-A0B0-A5CBD8A7E377}-S3717.json | 134 ++++++++++++++ ...61-269A-4501-B06A-026707F000A7}-S3717.json | 30 +++ ...FD-7C53-49C8-B9AA-02E458B3E6A7}-S3717.json | 69 +++++++ ...D0-BBDB-43E5-AFC4-ED1D3ECDC224}-S3717.json | 17 ++ ...B8-7E07-4457-ABF2-609B3E7B2649}-S3717.json | 30 +++ ...17-5E9D-40C4-9201-D092751532A7}-S3717.json | 30 +++ ...7D-70E3-4836-8B33-EC9A5AF72330}-S3717.json | 147 +++++++++++++++ sonaranalyzer-dotnet/rspec/cs/S3717_c#.html | 12 ++ sonaranalyzer-dotnet/rspec/cs/S3717_c#.json | 13 ++ .../RspecStrings.Designer.cs | 162 ++++++++++++++++ .../SonarAnalyzer.CSharp/RspecStrings.resx | 27 +++ .../Rules/TrackNotImplementedException.cs | 69 +++++++ .../Rules.Description/S3717.html | 12 ++ .../PackagingTests/RuleTypeTests.cs | 2 +- .../Rules/TrackNotImplementedExceptionTest.cs | 37 ++++ .../TestCases/TrackNotImplementedException.cs | 13 ++ 20 files changed, 1079 insertions(+), 1 deletion(-) create mode 100644 sonaranalyzer-dotnet/its/expected/Nancy/Nancy-{34576216-0DCA-4B0F-A0DC-9075E75A676F}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Authentication.Forms.Tests-{4E974051-38C2-4B5D-A6B1-F265A428A673}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Testing.Tests-{8EB9E15A-4B65-4C80-B834-9A7773750666}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Tests-{776D244D-BC4D-4BBB-A478-CAF2D04520E1}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/akka.net/Akka-{5DEDDF90-37F0-48D3-A0B0-A5CBD8A7E377}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/akka.net/Akka.Cluster-{6AB00F61-269A-4501-B06A-026707F000A7}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/akka.net/Akka.Remote-{EA4FF8FD-7C53-49C8-B9AA-02E458B3E6A7}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit-{0D3CBAD0-BBDB-43E5-AFC4-ED1D3ECDC224}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit.Xunit-{11F4D4B8-7E07-4457-ABF2-609B3E7B2649}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit.Xunit2-{7DBD5C17-5E9D-40C4-9201-D092751532A7}-S3717.json create mode 100644 sonaranalyzer-dotnet/its/expected/akka.net/Akka.Tests-{3F786C7D-70E3-4836-8B33-EC9A5AF72330}-S3717.json create mode 100644 sonaranalyzer-dotnet/rspec/cs/S3717_c#.html create mode 100644 sonaranalyzer-dotnet/rspec/cs/S3717_c#.json create mode 100644 sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/Rules/TrackNotImplementedException.cs create mode 100644 sonaranalyzer-dotnet/src/SonarAnalyzer.Utilities/Rules.Description/S3717.html create mode 100644 sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/Rules/TrackNotImplementedExceptionTest.cs create mode 100644 sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/TestCases/TrackNotImplementedException.cs diff --git a/sonaranalyzer-dotnet/its/expected/Nancy/Nancy-{34576216-0DCA-4B0F-A0DC-9075E75A676F}-S3717.json b/sonaranalyzer-dotnet/its/expected/Nancy/Nancy-{34576216-0DCA-4B0F-A0DC-9075E75A676F}-S3717.json new file mode 100644 index 00000000000..d712a1d8f5c --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/Nancy/Nancy-{34576216-0DCA-4B0F-A0DC-9075E75A676F}-S3717.json @@ -0,0 +1,30 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy\Json\Converters\TupleConverter.cs", +"region": { +"startLine": 34, +"startColumn": 13, +"endLine": 34, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy\ViewEngines\SuperSimpleViewEngine\NancyViewEngineHost.cs", +"region": { +"startLine": 64, +"startColumn": 13, +"endLine": 64, +"endColumn": 49 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Authentication.Forms.Tests-{4E974051-38C2-4B5D-A6B1-F265A428A673}-S3717.json b/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Authentication.Forms.Tests-{4E974051-38C2-4B5D-A6B1-F265A428A673}-S3717.json new file mode 100644 index 00000000000..2f8bd0afbff --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Authentication.Forms.Tests-{4E974051-38C2-4B5D-A6B1-F265A428A673}-S3717.json @@ -0,0 +1,56 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeNancyModuleWithBasePath.cs", +"region": { +"startLine": 10, +"startColumn": 17, +"endLine": 10, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeNancyModuleWithBasePath.cs", +"region": { +"startLine": 22, +"startColumn": 17, +"endLine": 22, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeNancyModuleWithBasePath.cs", +"region": { +"startLine": 30, +"startColumn": 17, +"endLine": 30, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeNancyModuleWithBasePath.cs", +"region": { +"startLine": 42, +"startColumn": 17, +"endLine": 42, +"endColumn": 53 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Testing.Tests-{8EB9E15A-4B65-4C80-B834-9A7773750666}-S3717.json b/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Testing.Tests-{8EB9E15A-4B65-4C80-B834-9A7773750666}-S3717.json new file mode 100644 index 00000000000..6928ab2e39b --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Testing.Tests-{8EB9E15A-4B65-4C80-B834-9A7773750666}-S3717.json @@ -0,0 +1,17 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Testing.Tests\ConfigurableBootstrapperFixture.cs", +"region": { +"startLine": 207, +"startColumn": 17, +"endLine": 207, +"endColumn": 53 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Tests-{776D244D-BC4D-4BBB-A478-CAF2D04520E1}-S3717.json b/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Tests-{776D244D-BC4D-4BBB-A478-CAF2D04520E1}-S3717.json new file mode 100644 index 00000000000..cf188c1ff45 --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/Nancy/Nancy.Tests-{776D244D-BC4D-4BBB-A478-CAF2D04520E1}-S3717.json @@ -0,0 +1,173 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeNancyModuleWithBasePath.cs", +"region": { +"startLine": 10, +"startColumn": 17, +"endLine": 10, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeNancyModuleWithBasePath.cs", +"region": { +"startLine": 22, +"startColumn": 17, +"endLine": 22, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeNancyModuleWithBasePath.cs", +"region": { +"startLine": 30, +"startColumn": 17, +"endLine": 30, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeNancyModuleWithBasePath.cs", +"region": { +"startLine": 42, +"startColumn": 17, +"endLine": 42, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Fakes\FakeViewEngineHost.cs", +"region": { +"startLine": 75, +"startColumn": 13, +"endLine": 75, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Unit\Bootstrapper\Base\BootstrapperBaseFixtureBase.cs", +"region": { +"startLine": 151, +"startColumn": 17, +"endLine": 151, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Unit\Bootstrapper\NancyBootstrapperBaseFixture.cs", +"region": { +"startLine": 401, +"startColumn": 13, +"endLine": 401, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Unit\Bootstrapper\NancyBootstrapperBaseFixture.cs", +"region": { +"startLine": 553, +"startColumn": 13, +"endLine": 553, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Unit\Bootstrapper\NancyBootstrapperBaseFixture.cs", +"region": { +"startLine": 564, +"startColumn": 13, +"endLine": 564, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Unit\Bootstrapper\NancyBootstrapperBaseFixture.cs", +"region": { +"startLine": 569, +"startColumn": 13, +"endLine": 569, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Unit\Bootstrapper\NancyBootstrapperWithRequestContainerBaseFixture.cs", +"region": { +"startLine": 297, +"startColumn": 17, +"endLine": 297, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Unit\DefaultSerializerFactoryFixture.cs", +"region": { +"startLine": 181, +"startColumn": 17, +"endLine": 181, +"endColumn": 60 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "Nancy\src\Nancy.Tests\Unit\DefaultSerializerFactoryFixture.cs", +"region": { +"startLine": 203, +"startColumn": 17, +"endLine": 203, +"endColumn": 60 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/akka.net/Akka-{5DEDDF90-37F0-48D3-A0B0-A5CBD8A7E377}-S3717.json b/sonaranalyzer-dotnet/its/expected/akka.net/Akka-{5DEDDF90-37F0-48D3-A0B0-A5CBD8A7E377}-S3717.json new file mode 100644 index 00000000000..efcdc9344f1 --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/akka.net/Akka-{5DEDDF90-37F0-48D3-A0B0-A5CBD8A7E377}-S3717.json @@ -0,0 +1,134 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Actor\ActorCell.DeathWatch.cs", +"region": { +"startLine": 303, +"startColumn": 17, +"endLine": 303, +"endColumn": 92 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Actor\ActorRef.cs", +"region": { +"startLine": 78, +"startColumn": 19, +"endLine": 78, +"endColumn": 55 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Configuration\Hocon\HoconArray.cs", +"region": { +"startLine": 49, +"startColumn": 13, +"endLine": 49, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Configuration\Hocon\HoconLiteral.cs", +"region": { +"startLine": 70, +"startColumn": 13, +"endLine": 70, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Configuration\Hocon\HoconObject.cs", +"region": { +"startLine": 86, +"startColumn": 13, +"endLine": 86, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Configuration\Hocon\HoconObject.cs", +"region": { +"startLine": 108, +"startColumn": 13, +"endLine": 108, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Routing\RouterConfig.cs", +"region": { +"startLine": 157, +"startColumn": 13, +"endLine": 157, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Routing\RouterConfig.cs", +"region": { +"startLine": 174, +"startColumn": 13, +"endLine": 174, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Routing\RouterConfig.cs", +"region": { +"startLine": 191, +"startColumn": 13, +"endLine": 191, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka\Routing\RouterConfig.cs", +"region": { +"startLine": 368, +"startColumn": 13, +"endLine": 368, +"endColumn": 49 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Cluster-{6AB00F61-269A-4501-B06A-026707F000A7}-S3717.json b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Cluster-{6AB00F61-269A-4501-B06A-026707F000A7}-S3717.json new file mode 100644 index 00000000000..1b75c0da5f3 --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Cluster-{6AB00F61-269A-4501-B06A-026707F000A7}-S3717.json @@ -0,0 +1,30 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Cluster\Routing\ClusterRoutingConfig.cs", +"region": { +"startLine": 149, +"startColumn": 13, +"endLine": 149, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Cluster\Routing\ClusterRoutingConfig.cs", +"region": { +"startLine": 273, +"startColumn": 13, +"endLine": 273, +"endColumn": 49 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Remote-{EA4FF8FD-7C53-49C8-B9AA-02E458B3E6A7}-S3717.json b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Remote-{EA4FF8FD-7C53-49C8-B9AA-02E458B3E6A7}-S3717.json new file mode 100644 index 00000000000..08e477e76a3 --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Remote-{EA4FF8FD-7C53-49C8-B9AA-02E458B3E6A7}-S3717.json @@ -0,0 +1,69 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Remote\RemoteActorRef.cs", +"region": { +"startLine": 102, +"startColumn": 13, +"endLine": 102, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Remote\Serialization\ProtobufSerializer.cs", +"region": { +"startLine": 52, +"startColumn": 13, +"endLine": 52, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Remote\Serialization\ProtobufSerializer.cs", +"region": { +"startLine": 69, +"startColumn": 13, +"endLine": 69, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Remote\Transport\Helios\HeliosTransport.cs", +"region": { +"startLine": 276, +"startColumn": 17, +"endLine": 276, +"endColumn": 101 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Remote\Transport\Helios\HeliosTransport.cs", +"region": { +"startLine": 284, +"startColumn": 17, +"endLine": 284, +"endColumn": 101 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit-{0D3CBAD0-BBDB-43E5-AFC4-ED1D3ECDC224}-S3717.json b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit-{0D3CBAD0-BBDB-43E5-AFC4-ED1D3ECDC224}-S3717.json new file mode 100644 index 00000000000..9906ea98cf1 --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit-{0D3CBAD0-BBDB-43E5-AFC4-ED1D3ECDC224}-S3717.json @@ -0,0 +1,17 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.TestKit\Internal\BlockingQueue.cs", +"region": { +"startLine": 193, +"startColumn": 44, +"endLine": 193, +"endColumn": 80 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit.Xunit-{11F4D4B8-7E07-4457-ABF2-609B3E7B2649}-S3717.json b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit.Xunit-{11F4D4B8-7E07-4457-ABF2-609B3E7B2649}-S3717.json new file mode 100644 index 00000000000..9be1623285a --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit.Xunit-{11F4D4B8-7E07-4457-ABF2-609B3E7B2649}-S3717.json @@ -0,0 +1,30 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\contrib\testkits\Akka.TestKit.Xunit\Internals\AkkaAssertEqualityComparer.cs", +"region": { +"startLine": 107, +"startColumn": 13, +"endLine": 107, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\contrib\testkits\Akka.TestKit.Xunit\Internals\AkkaAssertEqualityComparerAdapter.cs", +"region": { +"startLine": 43, +"startColumn": 13, +"endLine": 43, +"endColumn": 49 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit.Xunit2-{7DBD5C17-5E9D-40C4-9201-D092751532A7}-S3717.json b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit.Xunit2-{7DBD5C17-5E9D-40C4-9201-D092751532A7}-S3717.json new file mode 100644 index 00000000000..c315e619c6f --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.TestKit.Xunit2-{7DBD5C17-5E9D-40C4-9201-D092751532A7}-S3717.json @@ -0,0 +1,30 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\contrib\testkits\Akka.TestKit.Xunit2\Internals\AkkaAssertEqualityComparer.cs", +"region": { +"startLine": 107, +"startColumn": 13, +"endLine": 107, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\contrib\testkits\Akka.TestKit.Xunit2\Internals\AkkaAssertEqualityComparerAdapter.cs", +"region": { +"startLine": 43, +"startColumn": 13, +"endLine": 43, +"endColumn": 49 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Tests-{3F786C7D-70E3-4836-8B33-EC9A5AF72330}-S3717.json b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Tests-{3F786C7D-70E3-4836-8B33-EC9A5AF72330}-S3717.json new file mode 100644 index 00000000000..165271cd7af --- /dev/null +++ b/sonaranalyzer-dotnet/its/expected/akka.net/Akka.Tests-{3F786C7D-70E3-4836-8B33-EC9A5AF72330}-S3717.json @@ -0,0 +1,147 @@ +{ +"issues": [ +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Actor\ActorRefSpec.cs", +"region": { +"startLine": 585, +"startColumn": 17, +"endLine": 585, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Actor\ActorSystemSpec.cs", +"region": { +"startLine": 215, +"startColumn": 13, +"endLine": 215, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Actor\ActorSystemSpec.cs", +"region": { +"startLine": 220, +"startColumn": 13, +"endLine": 220, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Actor\ActorSystemSpec.cs", +"region": { +"startLine": 226, +"startColumn": 13, +"endLine": 226, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Actor\ActorSystemSpec.cs", +"region": { +"startLine": 232, +"startColumn": 13, +"endLine": 232, +"endColumn": 49 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Actor\RootGuardianActorRef_Tests.cs", +"region": { +"startLine": 107, +"startColumn": 23, +"endLine": 107, +"endColumn": 66 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\MatchHandler\CachedMatchCompilerTests.cs", +"region": { +"startLine": 188, +"startColumn": 17, +"endLine": 188, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\MatchHandler\MatchHandlerBuilderTests.cs", +"region": { +"startLine": 251, +"startColumn": 17, +"endLine": 251, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Serialization\SerializationSpec.cs", +"region": { +"startLine": 578, +"startColumn": 23, +"endLine": 578, +"endColumn": 59 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Serialization\SerializationSpec.cs", +"region": { +"startLine": 583, +"startColumn": 17, +"endLine": 583, +"endColumn": 53 +} +} +}, +{ +"id": "S3717", +"message": "Implement this method or throw 'NotSupportedException' instead.", +"location": { +"uri": "akka.net\src\core\Akka.Tests\Serialization\SerializationSpec.cs", +"region": { +"startLine": 588, +"startColumn": 17, +"endLine": 588, +"endColumn": 53 +} +} +} +] +} diff --git a/sonaranalyzer-dotnet/rspec/cs/S3717_c#.html b/sonaranalyzer-dotnet/rspec/cs/S3717_c#.html new file mode 100644 index 00000000000..14320cdd505 --- /dev/null +++ b/sonaranalyzer-dotnet/rspec/cs/S3717_c#.html @@ -0,0 +1,12 @@ +

NotImplementedException is often used to mark methods which must be implemented for the overall functionality to be complete, but +which the developer wants to implement later. That's as opposed to the NotSupportedException which is thrown by methods which are +required by base classes or interfaces, but which are not appropriate to the current class.

+

This rule raises an exception when NotImplementedException is thrown.

+

Noncompliant Code Example

+
+void doTheThing()
+{
+    throw new NotImplementedException();
+}
+
+ diff --git a/sonaranalyzer-dotnet/rspec/cs/S3717_c#.json b/sonaranalyzer-dotnet/rspec/cs/S3717_c#.json new file mode 100644 index 00000000000..a7d0bcc4574 --- /dev/null +++ b/sonaranalyzer-dotnet/rspec/cs/S3717_c#.json @@ -0,0 +1,13 @@ +{ + "title": "Track use of \"NotImplementedException\"", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": null + }, + "tags": [ + + ], + "defaultSeverity": "Minor" +} diff --git a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.Designer.cs b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.Designer.cs index 610be2478a6..193dac18285 100644 --- a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.Designer.cs +++ b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.Designer.cs @@ -6018,6 +6018,87 @@ internal static string S2070_Type { } } + /// + /// Looks up a localized string similar to Sonar Bug. + /// + internal static string S2114_Category { + get { + return ResourceManager.GetString("S2114_Category", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Passing a collection as an argument to the collection's own method is either an error - some other argument was intended - or simply nonsensical code. . + /// + internal static string S2114_Description { + get { + return ResourceManager.GetString("S2114_Description", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to True. + /// + internal static string S2114_IsActivatedByDefault { + get { + return ResourceManager.GetString("S2114_IsActivatedByDefault", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Constant/Issue. + /// + internal static string S2114_Remediation { + get { + return ResourceManager.GetString("S2114_Remediation", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to 15min. + /// + internal static string S2114_RemediationCost { + get { + return ResourceManager.GetString("S2114_RemediationCost", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Major. + /// + internal static string S2114_Severity { + get { + return ResourceManager.GetString("S2114_Severity", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to . + /// + internal static string S2114_Tags { + get { + return ResourceManager.GetString("S2114_Tags", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Collections should not be passed as arguments to their own methods. + /// + internal static string S2114_Title { + get { + return ResourceManager.GetString("S2114_Title", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to BUG. + /// + internal static string S2114_Type { + get { + return ResourceManager.GetString("S2114_Type", resourceCulture); + } + } + /// /// Looks up a localized string similar to Sonar Bug. /// @@ -16386,6 +16467,87 @@ internal static string S3655_Type { } } + /// + /// Looks up a localized string similar to Sonar Code Smell. + /// + internal static string S3717_Category { + get { + return ResourceManager.GetString("S3717_Category", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to NotImplementedException is often used to mark methods which must be implemented for the overall functionality to be complete, but which the developer wants to implement later. That's as opposed to the NotSupportedException which is thrown by methods which are required by base classes or interfaces, but which are not appropriate to the current class.. + /// + internal static string S3717_Description { + get { + return ResourceManager.GetString("S3717_Description", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to False. + /// + internal static string S3717_IsActivatedByDefault { + get { + return ResourceManager.GetString("S3717_IsActivatedByDefault", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Constant/Issue. + /// + internal static string S3717_Remediation { + get { + return ResourceManager.GetString("S3717_Remediation", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to . + /// + internal static string S3717_RemediationCost { + get { + return ResourceManager.GetString("S3717_RemediationCost", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Minor. + /// + internal static string S3717_Severity { + get { + return ResourceManager.GetString("S3717_Severity", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to . + /// + internal static string S3717_Tags { + get { + return ResourceManager.GetString("S3717_Tags", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Track use of "NotImplementedException". + /// + internal static string S3717_Title { + get { + return ResourceManager.GetString("S3717_Title", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to CODE_SMELL. + /// + internal static string S3717_Type { + get { + return ResourceManager.GetString("S3717_Type", resourceCulture); + } + } + /// /// Looks up a localized string similar to Sonar Code Smell. /// diff --git a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx index c4539be382e..36dbf150b81 100644 --- a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx +++ b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx @@ -5586,6 +5586,33 @@ BUG + + Sonar Code Smell + + + NotImplementedException is often used to mark methods which must be implemented for the overall functionality to be complete, but which the developer wants to implement later. That's as opposed to the NotSupportedException which is thrown by methods which are required by base classes or interfaces, but which are not appropriate to the current class. + + + False + + + Constant/Issue + + + + + + Minor + + + + + + Track use of "NotImplementedException" + + + CODE_SMELL + Sonar Code Smell diff --git a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/Rules/TrackNotImplementedException.cs b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/Rules/TrackNotImplementedException.cs new file mode 100644 index 00000000000..67138f9f613 --- /dev/null +++ b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/Rules/TrackNotImplementedException.cs @@ -0,0 +1,69 @@ +/* + * SonarAnalyzer for .NET + * Copyright (C) 2015-2017 SonarSource SA + * mailto: contact AT sonarsource DOT com + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 3 of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program; if not, write to the Free Software Foundation, + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +using System.Collections.Immutable; +using Microsoft.CodeAnalysis; +using Microsoft.CodeAnalysis.CSharp; +using Microsoft.CodeAnalysis.CSharp.Syntax; +using Microsoft.CodeAnalysis.Diagnostics; +using SonarAnalyzer.Common; +using SonarAnalyzer.Helpers; + +namespace SonarAnalyzer.Rules.CSharp +{ + [DiagnosticAnalyzer(LanguageNames.CSharp)] + [Rule(DiagnosticId)] + public sealed class TrackNotImplementedException : SonarDiagnosticAnalyzer + { + internal const string DiagnosticId = "S3717"; + private const string MessageFormat = "Implement this method or throw 'NotSupportedException' instead."; + + private static readonly DiagnosticDescriptor rule = + DiagnosticDescriptorBuilder.GetDescriptor(DiagnosticId, MessageFormat, RspecStrings.ResourceManager); + public override ImmutableArray SupportedDiagnostics => ImmutableArray.Create(rule); + + protected override void Initialize(SonarAnalysisContext context) + { + context.RegisterSyntaxNodeActionInNonGenerated( + c => + { + var throwStatement = (ThrowStatementSyntax)c.Node; + if (throwStatement.Expression == null) + { + return; + } + + var typeInfo = c.SemanticModel.GetTypeInfo(throwStatement.Expression); + + if (typeInfo.Type == null || + typeInfo.Type is IErrorTypeSymbol) + { + return; + } + + if (typeInfo.Type.Is(KnownType.System_NotImplementedException)) + { + c.ReportDiagnostic(Diagnostic.Create(rule, throwStatement.GetLocation())); + } + }, + SyntaxKind.ThrowStatement); + } + } +} diff --git a/sonaranalyzer-dotnet/src/SonarAnalyzer.Utilities/Rules.Description/S3717.html b/sonaranalyzer-dotnet/src/SonarAnalyzer.Utilities/Rules.Description/S3717.html new file mode 100644 index 00000000000..14320cdd505 --- /dev/null +++ b/sonaranalyzer-dotnet/src/SonarAnalyzer.Utilities/Rules.Description/S3717.html @@ -0,0 +1,12 @@ +

NotImplementedException is often used to mark methods which must be implemented for the overall functionality to be complete, but +which the developer wants to implement later. That's as opposed to the NotSupportedException which is thrown by methods which are +required by base classes or interfaces, but which are not appropriate to the current class.

+

This rule raises an exception when NotImplementedException is thrown.

+

Noncompliant Code Example

+
+void doTheThing()
+{
+    throw new NotImplementedException();
+}
+
+ diff --git a/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/PackagingTests/RuleTypeTests.cs b/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/PackagingTests/RuleTypeTests.cs index def2bf19043..82a04218020 100644 --- a/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/PackagingTests/RuleTypeTests.cs +++ b/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/PackagingTests/RuleTypeTests.cs @@ -3714,7 +3714,7 @@ private static void DetectTypeChanges(ResourceManager resourceManager, IImmutabl //["3714"], //["3715"], //["3716"], - //["3717"], + ["3717"] = "CODE_SMELL", //["3718"], //["3719"], //["3720"], diff --git a/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/Rules/TrackNotImplementedExceptionTest.cs b/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/Rules/TrackNotImplementedExceptionTest.cs new file mode 100644 index 00000000000..8a92fd75189 --- /dev/null +++ b/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/Rules/TrackNotImplementedExceptionTest.cs @@ -0,0 +1,37 @@ +/* + * SonarAnalyzer for .NET + * Copyright (C) 2015-2017 SonarSource SA + * mailto: contact AT sonarsource DOT com + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 3 of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program; if not, write to the Free Software Foundation, + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +using Microsoft.VisualStudio.TestTools.UnitTesting; +using SonarAnalyzer.Rules.CSharp; + +namespace SonarAnalyzer.UnitTest.Rules +{ + [TestClass] + public class TrackNotImplementedExceptionTest + { + [TestMethod] + [TestCategory("Rule")] + public void TrackNotImplementedException() + { + Verifier.VerifyAnalyzer(@"TestCases\TrackNotImplementedException.cs", + new TrackNotImplementedException()); + } + } +} diff --git a/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/TestCases/TrackNotImplementedException.cs b/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/TestCases/TrackNotImplementedException.cs new file mode 100644 index 00000000000..4bc79b6bdf8 --- /dev/null +++ b/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/TestCases/TrackNotImplementedException.cs @@ -0,0 +1,13 @@ +using System; + +namespace Tests.Diagnostics +{ + class Program + { + void Foo() + { + throw new NotImplementedException(); // Noncompliant {{Implement this method or throw 'NotSupportedException' instead.}} +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + } + } +} From 66ae0a315dc5612cbce418e8f73a4bd6617a2020 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Amaury=20Lev=C3=A9?= Date: Wed, 26 Jul 2017 14:23:13 +0200 Subject: [PATCH 2/4] Address review comments --- .../Rules/TrackNotImplementedException.cs | 10 +--------- .../TestCases/TrackNotImplementedException.cs | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+), 9 deletions(-) diff --git a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/Rules/TrackNotImplementedException.cs b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/Rules/TrackNotImplementedException.cs index 67138f9f613..e0b4b630011 100644 --- a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/Rules/TrackNotImplementedException.cs +++ b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/Rules/TrackNotImplementedException.cs @@ -50,15 +50,7 @@ protected override void Initialize(SonarAnalysisContext context) return; } - var typeInfo = c.SemanticModel.GetTypeInfo(throwStatement.Expression); - - if (typeInfo.Type == null || - typeInfo.Type is IErrorTypeSymbol) - { - return; - } - - if (typeInfo.Type.Is(KnownType.System_NotImplementedException)) + if (c.SemanticModel.GetTypeInfo(throwStatement.Expression).Type.Is(KnownType.System_NotImplementedException)) { c.ReportDiagnostic(Diagnostic.Create(rule, throwStatement.GetLocation())); } diff --git a/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/TestCases/TrackNotImplementedException.cs b/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/TestCases/TrackNotImplementedException.cs index 4bc79b6bdf8..0f80bc87702 100644 --- a/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/TestCases/TrackNotImplementedException.cs +++ b/sonaranalyzer-dotnet/src/Tests/SonarAnalyzer.UnitTest/TestCases/TrackNotImplementedException.cs @@ -2,6 +2,8 @@ namespace Tests.Diagnostics { + class MyException : NotImplementedException { } + class Program { void Foo() @@ -9,5 +11,22 @@ void Foo() throw new NotImplementedException(); // Noncompliant {{Implement this method or throw 'NotSupportedException' instead.}} // ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ } + + void Bar() + { + throw new MyException(); // Compliant - we don't check inheritance + } + + void FooBar() + { + var ex = new NotImplementedException(); // Compliant - not thrown + } + + void FooBar2() + { + var ex = new NotImplementedException(); + throw ex; // Noncompliant +// ^^^^^^^^^ + } } } From d8aa7ca0cc22e4b534d82e77dde12071c9e315ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Amaury=20Lev=C3=A9?= Date: Wed, 26 Jul 2017 14:52:49 +0200 Subject: [PATCH 3/4] Update RSPEC metadata --- sonaranalyzer-dotnet/rspec/cs/S3717_c#.html | 2 + .../SonarAnalyzer.CSharp/RspecStrings.resx | 54 +++++++++---------- .../Rules.Description/S3717.html | 2 + 3 files changed, 31 insertions(+), 27 deletions(-) diff --git a/sonaranalyzer-dotnet/rspec/cs/S3717_c#.html b/sonaranalyzer-dotnet/rspec/cs/S3717_c#.html index 14320cdd505..47bfc435b12 100644 --- a/sonaranalyzer-dotnet/rspec/cs/S3717_c#.html +++ b/sonaranalyzer-dotnet/rspec/cs/S3717_c#.html @@ -9,4 +9,6 @@

Noncompliant Code Example

throw new NotImplementedException(); } +

Exceptions

+

The rule doesn't raise any issue if the thrown exception derives from NotImplementedException.

diff --git a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx index 36dbf150b81..330b1a5254f 100644 --- a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx +++ b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx @@ -1,17 +1,17 @@  - diff --git a/sonaranalyzer-dotnet/src/SonarAnalyzer.Utilities/Rules.Description/S3717.html b/sonaranalyzer-dotnet/src/SonarAnalyzer.Utilities/Rules.Description/S3717.html index 14320cdd505..47bfc435b12 100644 --- a/sonaranalyzer-dotnet/src/SonarAnalyzer.Utilities/Rules.Description/S3717.html +++ b/sonaranalyzer-dotnet/src/SonarAnalyzer.Utilities/Rules.Description/S3717.html @@ -9,4 +9,6 @@

Noncompliant Code Example

throw new NotImplementedException(); } +

Exceptions

+

The rule doesn't raise any issue if the thrown exception derives from NotImplementedException.

From 08745cf860a5ce53de69c5b0863e3ced73fa352f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Amaury=20Lev=C3=A9?= Date: Wed, 26 Jul 2017 14:53:50 +0200 Subject: [PATCH 4/4] Revert spaces added by rspec script --- .../SonarAnalyzer.CSharp/RspecStrings.resx | 54 +++++++++---------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx index 330b1a5254f..36dbf150b81 100644 --- a/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx +++ b/sonaranalyzer-dotnet/src/SonarAnalyzer.CSharp/RspecStrings.resx @@ -1,17 +1,17 @@  -