mirror of
https://github.com/shirou/gopsutil.git
synced 2025-04-29 13:49:21 +08:00
net: Check for error object
This commit is contained in:
parent
0225d9ddcc
commit
9d003ad2e1
@ -61,6 +61,9 @@ func TestNetConnectionStatString(t *testing.T) {
|
|||||||
|
|
||||||
func TestNetIOCountersAll(t *testing.T) {
|
func TestNetIOCountersAll(t *testing.T) {
|
||||||
v, err := IOCounters(false)
|
v, err := IOCounters(false)
|
||||||
|
if err != nil {
|
||||||
|
t.Errorf("Could not get NetIOCounters: %v", err)
|
||||||
|
}
|
||||||
per, err := IOCounters(true)
|
per, err := IOCounters(true)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Errorf("Could not get NetIOCounters: %v", err)
|
t.Errorf("Could not get NetIOCounters: %v", err)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user