gitlabhq/gitlab-shell

View on GitHub
cmd/gitlab-shell/command/command_test.go

Summary

Maintainability
C
1 day
Test Coverage

Function TestParseSuccess has 132 lines of code (exceeds 50 allowed). Consider refactoring.
Open

func TestParseSuccess(t *testing.T) {
    testCases := []struct {
        desc         string
        executable   *executable.Executable
        env          sshenv.Env
Severity: Major
Found in cmd/gitlab-shell/command/command_test.go - About 4 hrs to fix

    Function TestNewWithUsername has 75 lines of code (exceeds 50 allowed). Consider refactoring.
    Open

    func TestNewWithUsername(t *testing.T) {
        tests := []struct {
            desc         string
            command      string
            namespace    string
    Severity: Minor
    Found in cmd/gitlab-shell/command/command_test.go - About 2 hrs to fix

      Function TestNew has 72 lines of code (exceeds 50 allowed). Consider refactoring.
      Open

      func TestNew(t *testing.T) {
          testCases := []struct {
              desc         string
              executable   *executable.Executable
              env          sshenv.Env
      Severity: Minor
      Found in cmd/gitlab-shell/command/command_test.go - About 1 hr to fix

        There are no issues that match your filters.

        Category
        Status