Promact/slack-erp-custom-integration-mvc

View on GitHub
Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs

Summary

Maintainability
F
2 wks
Test Coverage

File TaskMailRepositoryTest.cs has 880 lines of code (exceeds 250 allowed). Consider refactoring.
Open

using Autofac;
using Autofac.Extras.NLog;
using Microsoft.AspNet.Identity;
using Moq;
using Promact.Core.Repository.BotQuestionRepository;
Severity: Major
Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 2 days to fix

    Class TaskMailRepositoryTest has 42 methods (exceeds 20 allowed). Consider refactoring.
    Open

        public class TaskMailRepositoryTest
        {
            #region Private Variables
            private readonly IComponentContext _componentContext;
            private readonly ITaskMailRepository _taskMailRepository;
    Severity: Minor
    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 5 hrs to fix

      Method Initialize has 57 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

              public void Initialize()
              {
      
                  profile.Skype = _stringConstant.TestUserId;
                  profile.Email = _stringConstant.EmailForTest;
      Severity: Major
      Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 2 hrs to fix

        Method TaskMailDetailsReportNextPreviousDateForEmployeeAsync has 32 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                [Fact, Trait("Category", "Required")]
                public async Task TaskMailDetailsReportNextPreviousDateForEmployeeAsync()
                {
                    var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                    var userRequestUrl = string.Format(_stringConstant.FirstAndSecondIndexStringFormat, _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
        Severity: Minor
        Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 1 hr to fix

          Method TaskMailDetailsReportNextPreviousDateAsync has 32 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  [Fact, Trait("Category", "Required")]
                  public async Task TaskMailDetailsReportNextPreviousDateAsync()
                  {
                      var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                      var userRequestUrl = string.Format(_stringConstant.FirstAndSecondIndexStringFormat, _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
          Severity: Minor
          Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 1 hr to fix

            Method QuestionAndAnswerAfterSecondAnswerExceedHoursAsync has 29 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                    [Fact, Trait("Category", "Required")]
                    public async Task QuestionAndAnswerAfterSecondAnswerExceedHoursAsync()
                    {
                        await mockAndUserCreate();
                        await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
            Severity: Minor
            Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 1 hr to fix

              Method TaskMailDetailsReportNextPreviousDateForTeamLeaderAsync has 28 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      [Fact, Trait("Category", "Required")]
                      public async Task TaskMailDetailsReportNextPreviousDateForTeamLeaderAsync()
                      {
                          var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                          var userRequestUrl = string.Format("{0}{1}", _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
              Severity: Minor
              Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 1 hr to fix

                Method TaskMailDetailsForSelectedDateForTeamLeaderAsync has 26 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        [Fact, Trait("Category", "Required")]
                        public async Task TaskMailDetailsForSelectedDateForTeamLeaderAsync()
                        {
                            await CreateUserAndMockingHttpContextToReturnAccessToken();
                            var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                Severity: Minor
                Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 1 hr to fix

                  Method TaskMailDetailsReportTeamLeaderAsync has 26 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                          [Fact, Trait("Category", "Required")]
                          public async Task TaskMailDetailsReportTeamLeaderAsync()
                          {
                              await CreateUserAndMockingHttpContextToReturnAccessToken();
                              var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                  Severity: Minor
                  Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs - About 1 hr to fix

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task TaskMailDetailsReportNextPreviousDateForEmployeeAsync()
                            {
                                var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                                var userRequestUrl = string.Format(_stringConstant.FirstAndSecondIndexStringFormat, _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 1 day to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 786..821

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 680.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task TaskMailDetailsReportNextPreviousDateAsync()
                            {
                                var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                                var userRequestUrl = string.Format(_stringConstant.FirstAndSecondIndexStringFormat, _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 1 day to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 826..861

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 680.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task TaskMailDetailsForSelectedDateForAdminAsync()
                            {
                                var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                                var userRequestUrl = string.Format("{0}{1}", _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 1 day to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 640..666

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 603.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task TaskMailDetailsForSelectedDateAsync()
                            {
                                var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                                var userRequestUrl = string.Format("{0}{1}", _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 1 day to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 673..699

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 603.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task TaskMailDetailsReportAsync()
                            {
                                var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                                var userRequestUrl = string.Format("{0}{1}", _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 1 day to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 542..568

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 581.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task TaskMailDetailsReportForEmployeeAsync()
                            {
                                var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                                var userRequestUrl = string.Format("{0}{1}", _stringConstant.UserDetailsUrl, _stringConstant.FirstNameForTest);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 1 day to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 511..537

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 581.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            private async Task mockAndUserCreateAsync()
                            {
                                var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                                var userRequestUrl = string.Format(_stringConstant.FirstAndSecondIndexStringFormat, _stringConstant.DetailsAndSlashForUrl, _stringConstant.StringIdForTest);
                                _mockHttpClient.Setup(x => x.GetAsync(_stringConstant.ProjectUserUrl, userRequestUrl, _stringConstant.AccessTokenForTest, _stringConstant.Bearer)).Returns(userResponse);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 5 hrs to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 962..976

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 382.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            private async Task mockAndUserCreate()
                            {
                                var userResponse = Task.FromResult(_stringConstant.UserDetailsFromOauthServer);
                                var userRequestUrl = string.Format(_stringConstant.FirstAndSecondIndexStringFormat, _stringConstant.DetailsAndSlashForUrl, _stringConstant.StringIdForTest);
                                _mockHttpClient.Setup(x => x.GetAsync(_stringConstant.ProjectUserUrl, userRequestUrl, _stringConstant.AccessTokenForTest, _stringConstant.Bearer)).Returns(userResponse);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 5 hrs to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 492..506

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 382.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 6 locations. Consider refactoring.
                    Open

                            private async Task CreateUserAndMockingHttpContextToReturnAccessToken()
                            {
                                var user = new ApplicationUser()
                                {
                                    Id = _stringConstant.StringIdForTest,
                    Slack.Automation/Promact.Core.Test/LeaveReportRepositoryTest.cs on lines 176..195
                    Slack.Automation/Promact.Core.Test/MailSettingDetailsByProjectAndModuleTest.cs on lines 208..227
                    Slack.Automation/Promact.Core.Test/MailSettingRepositoryTest.cs on lines 137..156
                    Slack.Automation/Promact.Core.Test/OauthCallsRepositoryTest.cs on lines 385..404
                    Slack.Automation/Promact.Core.Test/ScrumReportRepositoryTest.cs on lines 255..274

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 314.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterSecondAnswerForStringAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 3 hrs to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 939..955

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 235.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterSecondAnswerForLimitExceedAnswerAsync()
                            {
                                await mockAndUserCreate();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 3 hrs to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 229..245

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 235.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 4 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerThirdNotAnsweredOrWrongAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 209..224
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 349..364
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 410..425

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 217.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 4 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerSixthNotAnsweredOrWrongAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 209..224
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 270..285
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 349..364

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 217.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 4 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerSecondNotAnsweredOrWrongAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 270..285
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 349..364
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 410..425

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 217.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 4 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerFifthNotAnsweredOrWrongAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 209..224
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 270..285
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 410..425

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 217.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 7 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterThirdAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 189..204
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 250..265
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 329..344
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 369..384
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 451..466
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 471..486

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 197.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 7 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterSendingMailAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 189..204
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 250..265
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 290..305
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 329..344
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 369..384
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 451..466

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 197.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 7 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterSecondAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 189..204
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 290..305
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 329..344
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 369..384
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 451..466
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 471..486

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 197.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 7 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterForthAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 189..204
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 250..265
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 290..305
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 369..384
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 451..466
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 471..486

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 197.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 7 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterFifthAnswerForYesAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 189..204
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 250..265
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 290..305
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 329..344
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 451..466
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 471..486

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 197.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 7 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterSixthAnswerForNoAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 189..204
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 250..265
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 290..305
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 329..344
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 369..384
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 471..486

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 197.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 7 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerAfterFirstAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 250..265
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 290..305
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 329..344
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 369..384
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 451..466
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 471..486

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 197.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 3 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task GetAllEmployeeForTeamLeaderAsync()
                            {
                                await CreateUserAndMockingHttpContextToReturnAccessToken();
                                var response = Task.FromResult(_stringConstant.ListOfEmployeeForTeamLeader);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 705..716
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 738..748

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 183.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 3 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task GetAllEmployeeAsync()
                            {
                                await CreateUserAndMockingHttpContextToReturnAccessToken();
                                var response = Task.FromResult(_stringConstant.TaskMailReport);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 721..731
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 738..748

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 183.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 3 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task GetEmployeeInfromationAsync()
                            {
                                await CreateUserAndMockingHttpContextToReturnAccessToken();
                                var response = Task.FromResult(_stringConstant.EmployeeInformation);
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 705..716
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 721..731

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 183.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerForthNotAnsweredOrWrongAnswerAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 2 hrs to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 130..144

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 179.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    Similar blocks of code found in 2 locations. Consider refactoring.
                    Open

                            [Fact, Trait("Category", "Required")]
                            public async Task QuestionAndAnswerFirstNotAnsweredAsync()
                            {
                                await mockAndUserCreateAsync();
                                await _slackUserRepository.AddSlackUserAsync(slackUserDetails);
                    Severity: Major
                    Found in Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs and 1 other location - About 2 hrs to fix
                    Slack.Automation/Promact.Core.Test/TaskMailRepositoryTest.cs on lines 310..324

                    Duplicated Code

                    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                    Tuning

                    This issue has a mass of 179.

                    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                    Refactorings

                    Further Reading

                    There are no issues that match your filters.

                    Category
                    Status