add tests
Co-authored-by: grumbulon <grumbulon@grumbulon.xyz> Signed-off-by: Sam Therapy <sam@samtherapy.net>
This commit is contained in:
parent
9e22c2b145
commit
5b058125ae
1 changed files with 11 additions and 0 deletions
11
main_test.go
11
main_test.go
|
@ -27,6 +27,17 @@ func TestRun(t *testing.T) {
|
|||
}
|
||||
}
|
||||
|
||||
func TestTrace(t *testing.T) {
|
||||
domains := []string{"git.froth.zone", "google.com", "amazon.com", "freecumextremist.com", "dns.froth.zone", "sleepy.cafe", "pkg.go.dev"}
|
||||
|
||||
for i := range domains {
|
||||
args := []string{"awl", "+trace", domains[i], "@1.1.1.1"}
|
||||
_, code, err := run(args)
|
||||
assert.NilError(t, err)
|
||||
assert.Equal(t, code, 0)
|
||||
}
|
||||
}
|
||||
|
||||
func TestHelp(t *testing.T) {
|
||||
// t.Parallel()
|
||||
args := []string{"awl", "-h"}
|
||||
|
|
Loading…
Reference in a new issue