gatus/config/web_test.go

16 lines
270 B
Go
Raw Normal View History

2020-11-20 23:45:25 +01:00
package config
2020-11-21 04:07:38 +01:00
import (
"testing"
)
2020-11-20 23:45:25 +01:00
func TestWebConfig_SocketAddress(t *testing.T) {
2021-02-01 07:37:56 +01:00
web := &WebConfig{
2020-11-20 23:45:25 +01:00
Address: "0.0.0.0",
Port: 8081,
}
if web.SocketAddress() != "0.0.0.0:8081" {
t.Errorf("expected %s, got %s", "0.0.0.0:8081", web.SocketAddress())
}
}