Fix issues with failing tests on darwin (#7042)
This commit is contained in:
parent
397a04aa32
commit
8b3bd2585d
|
@ -42,14 +42,16 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- "11211:11211"
|
- "11211:11211"
|
||||||
pgbouncer:
|
pgbouncer:
|
||||||
image: mbed/pgbouncer
|
image: mbentley/ubuntu-pgbouncer
|
||||||
environment:
|
environment:
|
||||||
PG_ENV_POSTGRESQL_USER: pgbouncer
|
- PG_ENV_POSTGRESQL_USER=pgbouncer
|
||||||
PG_ENV_POSTGRESQL_PASS: pgbouncer
|
- PG_ENV_POSTGRESQL_PASS=pgbouncer
|
||||||
ports:
|
ports:
|
||||||
- "6432:6432"
|
- "6432:6432"
|
||||||
postgres:
|
postgres:
|
||||||
image: postgres:alpine
|
image: postgres:alpine
|
||||||
|
environment:
|
||||||
|
- POSTGRES_HOST_AUTH_METHOD=trust
|
||||||
ports:
|
ports:
|
||||||
- "5432:5432"
|
- "5432:5432"
|
||||||
rabbitmq:
|
rabbitmq:
|
||||||
|
@ -96,6 +98,5 @@ services:
|
||||||
- crate
|
- crate
|
||||||
- -Cnetwork.host=0.0.0.0
|
- -Cnetwork.host=0.0.0.0
|
||||||
- -Ctransport.host=localhost
|
- -Ctransport.host=localhost
|
||||||
- -Clicense.enterprise=false
|
|
||||||
environment:
|
environment:
|
||||||
- CRATE_HEAP_SIZE=128m
|
- CRATE_HEAP_SIZE=128m
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// +build linux
|
||||||
|
|
||||||
package ethtool
|
package ethtool
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
|
|
@ -210,6 +210,7 @@ func TestPostgresqlSqlScript(t *testing.T) {
|
||||||
Tagvalue: "",
|
Tagvalue: "",
|
||||||
}}
|
}}
|
||||||
p := &Postgresql{
|
p := &Postgresql{
|
||||||
|
Log: testutil.Logger{},
|
||||||
Service: postgresql.Service{
|
Service: postgresql.Service{
|
||||||
Address: fmt.Sprintf(
|
Address: fmt.Sprintf(
|
||||||
"host=%s user=postgres sslmode=disable",
|
"host=%s user=postgres sslmode=disable",
|
||||||
|
|
|
@ -3,6 +3,7 @@ package powerdns_recursor
|
||||||
import (
|
import (
|
||||||
"net"
|
"net"
|
||||||
"os"
|
"os"
|
||||||
|
"runtime"
|
||||||
"sync"
|
"sync"
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"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"
|
"x-ourtime2-4\t302\nx-ourtime4-8\t194\nx-ourtime8-16\t24\n"
|
||||||
|
|
||||||
func TestPowerdnsRecursorGeneratesMetrics(t *testing.T) {
|
func TestPowerdnsRecursorGeneratesMetrics(t *testing.T) {
|
||||||
|
if runtime.GOOS == "darwin" {
|
||||||
|
t.Skip("Skipping test on darwin")
|
||||||
|
}
|
||||||
// We create a fake server to return test data
|
// We create a fake server to return test data
|
||||||
controlSocket := "/tmp/pdns5724354148158589552.controlsocket"
|
controlSocket := "/tmp/pdns5724354148158589552.controlsocket"
|
||||||
addr, err := net.ResolveUnixAddr("unixgram", controlSocket)
|
addr, err := net.ResolveUnixAddr("unixgram", controlSocket)
|
||||||
|
|
|
@ -122,6 +122,9 @@ func TestFromProcFilesWithSpaceInCmd(t *testing.T) {
|
||||||
// However, we have had reports of this process state on Ubuntu
|
// However, we have had reports of this process state on Ubuntu
|
||||||
// Bionic w/ Linux 4.15 (#6270)
|
// Bionic w/ Linux 4.15 (#6270)
|
||||||
func TestParkedProcess(t *testing.T) {
|
func TestParkedProcess(t *testing.T) {
|
||||||
|
if runtime.GOOS != "linux" {
|
||||||
|
t.Skip("Parked process test only relevant on linux")
|
||||||
|
}
|
||||||
procstat := `88 (watchdog/13) P 2 0 0 0 -1 69238848 0 0 0 0 0 0 0 0 20 0 1 0 20 0 0 18446744073709551615 0 0 0 0 0 0 0 2147483647 0 1 0 0 17 0 0 0 0 0 0 0 0 0 0 0 0 0 0
|
procstat := `88 (watchdog/13) P 2 0 0 0 -1 69238848 0 0 0 0 0 0 0 0 20 0 1 0 20 0 0 18446744073709551615 0 0 0 0 0 0 0 2147483647 0 1 0 0 17 0 0 0 0 0 0 0 0 0 0 0 0 0 0
|
||||||
`
|
`
|
||||||
plugin := &Processes{
|
plugin := &Processes{
|
||||||
|
|
|
@ -17,11 +17,6 @@ import (
|
||||||
|
|
||||||
func getTestCasesForRFC5426() []testCasePacket {
|
func getTestCasesForRFC5426() []testCasePacket {
|
||||||
testCases := []testCasePacket{
|
testCases := []testCasePacket{
|
||||||
{
|
|
||||||
name: "empty",
|
|
||||||
data: []byte(""),
|
|
||||||
werr: true,
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
name: "complete",
|
name: "complete",
|
||||||
data: []byte("<1>1 - - - - - - A"),
|
data: []byte("<1>1 - - - - - - A"),
|
||||||
|
|
Loading…
Reference in New Issue