gitlabhq/gitlab-shell

View on GitHub
internal/command/twofactorverify/twofactorverify_test.go

Summary

Maintainability
A
2 hrs
Test Coverage

Function TestExecute has 68 lines of code (exceeds 50 allowed). Consider refactoring.
Open

func TestExecute(t *testing.T) {
    requests := setup(t)

    url := testserver.StartSocketHttpServer(t, requests)

Severity: Minor
Found in internal/command/twofactorverify/twofactorverify_test.go - About 1 hr to fix

    Function setup has 52 lines of code (exceeds 50 allowed). Consider refactoring.
    Open

    func setup(t *testing.T) []testserver.TestRequestHandler {
        waitInfinitely := make(chan struct{})
        requests := []testserver.TestRequestHandler{
            {
                Path: "/api/v4/internal/two_factor_manual_otp_check",
    Severity: Minor
    Found in internal/command/twofactorverify/twofactorverify_test.go - About 1 hr to fix

      There are no issues that match your filters.

      Category
      Status