func receivePacket(t *testing.T) *SnmpPacket {
	select {
	case packet := <-GetPacketsChannel():
		return packet
	case <-time.After(3 * time.Second):
		t.Error("Trap not received")
		return nil
	}
}
// receivePacket waits for a received trap packet and returns it.
receivePacket waits for a received trap packet and returns it.
// receivePacket waits for a received trap packet and returns it .
func receivePacket(t *testing.T) *SnmpPacket {
	select {
	case packet := <-GetPacketsChannel():
		return packet
	case <-time.After(3 * time.Second):
		t.Error("Trap not received")
		return nil
	}
}
func receivePacket ( t * testing . T ) * SnmpPacket { select { case packet := <- GetPacketsChannel ( ) : return packet case <- time . After ( 3 * time . Second ) : t . Error ( " " ) return nil } }
receivePacket waits for a received trap packet and returns it.
receivePacket waits for a received trap packet and returns it .