probe/discovery/protocol/snmp/snmp_test.go

24 lines
384 B
Go
Raw Normal View History

2018-08-29 12:04:23 +00:00
package snmp
import (
"testing"
omd "git.loafle.net/overflow/model/discovery"
omm "git.loafle.net/overflow/model/meta"
)
func TestSNMPScan(t *testing.T) {
host := &omd.Host{
MetaIPType: omm.ToMetaIPType(omm.MetaIPTypeEnumV4),
Address: "192.168.1.229",
}
ch := make(chan *SNMPResponse)
defer close(ch)
ScanSNMP(host, "test1252serc", ch)
msg := <-ch
t.Log(msg)
}