Skip to content

TestGatherMetrics_EndToEnd is unstable #958

@tigrannajaryan

Description

@tigrannajaryan

The test appears to be timing sensitive. Fails on my machine with the following:

--- FAIL: TestGatherMetrics_EndToEnd (0.19s)
    hostmetrics_receiver_test.go:106: 
        	Error Trace:	hostmetrics_receiver_test.go:106
        	Error:      	Not equal: 
        	            	expected: 5
        	            	actual  : 4
        	Test:       	TestGatherMetrics_EndToEnd
    hostmetrics_receiver_test.go:119: 
        	Error Trace:	hostmetrics_receiver_test.go:119
        	Error:      	Not equal: 
        	            	expected: 12
        	            	actual  : 7
        	Test:       	TestGatherMetrics_EndToEnd
    hostmetrics_receiver_test.go:121: 
        	Error Trace:	hostmetrics_receiver_test.go:121
        	Error:      	"map[host/cpu/time:%!s(bool=true) host/disk/bytes:%!s(bool=true) host/disk/ops:%!s(bool=true) host/disk/time:%!s(bool=true) host/filesystem/inodes/used:%!s(bool=true) host/filesystem/used:%!s(bool=true) host/memory/used:%!s(bool=true)]" does not contain "host/network/packets"
        	Test:       	TestGatherMetrics_EndToEnd
    hostmetrics_receiver_test.go:121: 
        	Error Trace:	hostmetrics_receiver_test.go:121
        	Error:      	"map[host/cpu/time:%!s(bool=true) host/disk/bytes:%!s(bool=true) host/disk/ops:%!s(bool=true) host/disk/time:%!s(bool=true) host/filesystem/inodes/used:%!s(bool=true) host/filesystem/used:%!s(bool=true) host/memory/used:%!s(bool=true)]" does not contain "host/network/dropped_packets"
        	Test:       	TestGatherMetrics_EndToEnd
    hostmetrics_receiver_test.go:121: 
        	Error Trace:	hostmetrics_receiver_test.go:121
        	Error:      	"map[host/cpu/time:%!s(bool=true) host/disk/bytes:%!s(bool=true) host/disk/ops:%!s(bool=true) host/disk/time:%!s(bool=true) host/filesystem/inodes/used:%!s(bool=true) host/filesystem/used:%!s(bool=true) host/memory/used:%!s(bool=true)]" does not contain "host/network/errors"
        	Test:       	TestGatherMetrics_EndToEnd
    hostmetrics_receiver_test.go:121: 
        	Error Trace:	hostmetrics_receiver_test.go:121
        	Error:      	"map[host/cpu/time:%!s(bool=true) host/disk/bytes:%!s(bool=true) host/disk/ops:%!s(bool=true) host/disk/time:%!s(bool=true) host/filesystem/inodes/used:%!s(bool=true) host/filesystem/used:%!s(bool=true) host/memory/used:%!s(bool=true)]" does not contain "host/network/bytes"
        	Test:       	TestGatherMetrics_EndToEnd
    hostmetrics_receiver_test.go:121: 
        	Error Trace:	hostmetrics_receiver_test.go:121
        	Error:      	"map[host/cpu/time:%!s(bool=true) host/disk/bytes:%!s(bool=true) host/disk/ops:%!s(bool=true) host/disk/time:%!s(bool=true) host/filesystem/inodes/used:%!s(bool=true) host/filesystem/used:%!s(bool=true) host/memory/used:%!s(bool=true)]" does not contain "host/network/tcp_connections"
        	Test:       	TestGatherMetrics_EndToEnd
FAIL
FAIL	github.com/open-telemetry/opentelemetry-collector/receiver/hostmetricsreceiver	1.531s

This is running on Mac OS X 10.14.6, go version go1.14.1 darwin/amd64

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions