mirror of
https://github.com/pomerium/pomerium.git
synced 2025-08-04 01:09:36 +02:00
upstream endpoints load balancer weights (#1830)
This commit is contained in:
parent
3567183ce5
commit
67f6030e1e
30 changed files with 1190 additions and 778 deletions
|
@ -28,6 +28,7 @@ import (
|
|||
"github.com/google/go-cmp/cmp"
|
||||
"github.com/google/uuid"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"github.com/pomerium/pomerium/config"
|
||||
)
|
||||
|
@ -144,8 +145,11 @@ func TestConfig(t *testing.T) {
|
|||
addr := li.Addr().String()
|
||||
_ = li.Close()
|
||||
|
||||
to, err := config.ParseWeightedUrls("http://to.example.com")
|
||||
require.NoError(t, err)
|
||||
|
||||
p1 := config.Policy{
|
||||
From: "http://from.example.com", To: config.NewStringSlice("http://to.example.com"),
|
||||
From: "http://from.example.com", To: to,
|
||||
}
|
||||
_ = p1.Validate()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue