mirror of
https://github.com/bettercap/bettercap
synced 2025-07-31 12:10:10 -07:00
add test for SetInts function
This commit is contained in:
parent
b8a0b86282
commit
00d6100214
1 changed files with 12 additions and 0 deletions
|
@ -45,3 +45,15 @@ func TestMetaGetIntsWith(t *testing.T) {
|
||||||
t.Fatalf("expected '%v', got '%v'", exp, got)
|
t.Fatalf("expected '%v', got '%v'", exp, got)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func TestMetaSetInts(t *testing.T) {
|
||||||
|
example := buildExampleMeta()
|
||||||
|
example.SetInts("picat", []int{0, 1})
|
||||||
|
|
||||||
|
exp := strings.Join([]string{"0", "1"}, ",")
|
||||||
|
got := example.m["picat"]
|
||||||
|
|
||||||
|
if exp != got {
|
||||||
|
t.Fatalf("expected '%v', got '%v'", exp, got)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue