Fix issues with failing tests on darwin (#7042)

This commit is contained in:
Steven Soroka
2020-02-18 19:13:54 -05:00
committed by GitHub
parent 397a04aa32
commit 8b3bd2585d
6 changed files with 15 additions and 9 deletions

View File

@@ -3,6 +3,7 @@ package powerdns_recursor
import (
"net"
"os"
"runtime"
"sync"
"testing"
"time"
@@ -98,6 +99,9 @@ var intOverflowMetrics = "all-outqueries\t18446744073709550195\nanswers-slow\t36
"x-ourtime2-4\t302\nx-ourtime4-8\t194\nx-ourtime8-16\t24\n"
func TestPowerdnsRecursorGeneratesMetrics(t *testing.T) {
if runtime.GOOS == "darwin" {
t.Skip("Skipping test on darwin")
}
// We create a fake server to return test data
controlSocket := "/tmp/pdns5724354148158589552.controlsocket"
addr, err := net.ResolveUnixAddr("unixgram", controlSocket)