internal/utils_test.go   A
last analyzed

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
cc 2
eloc 10
dl 0
loc 15
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A internal.TestParseArgsCorrectly 0 6 2
1
package internal
2
3
import (
4
    "fmt"
5
    "testing"
6
)
7
8
9
// Test that parse args correctly returns the command and args
10
func TestParseArgsCorrectly(t *testing.T) {
11
    progArgs := []string{"qdbg", "cmd", "arg1", "arg2"}
12
    cmd, args := ParseArgs(progArgs)
13
    fmt.Println(args)
14
    if cmd != "cmd" {
15
        t.Fatalf("Error in ParseArgs. Got command %s but expected `cmd`", cmd)
16
    }
17
}
18