mirror of https://github.com/status-im/consul.git
Retry checks for virtual IP metadata
This commit is contained in:
parent
62ed0250c3
commit
8ead1caf53
|
@ -1213,10 +1213,12 @@ func registerTestRoutingConfigTopologyEntries(t *testing.T, codec rpc.ClientCode
|
|||
func registerLocalAndRemoteServicesVIPEnabled(t *testing.T, state *state.Store) {
|
||||
t.Helper()
|
||||
|
||||
_, entry, err := state.SystemMetadataGet(nil, structs.SystemMetadataVirtualIPsEnabled)
|
||||
require.NoError(t, err)
|
||||
require.NotNil(t, entry)
|
||||
require.Equal(t, "true", entry.Value)
|
||||
retry.Run(t, func(r *retry.R) {
|
||||
_, entry, err := state.SystemMetadataGet(nil, structs.SystemMetadataVirtualIPsEnabled)
|
||||
require.NoError(r, err)
|
||||
require.NotNil(r, entry)
|
||||
require.Equal(r, "true", entry.Value)
|
||||
})
|
||||
|
||||
// Register a local connect-native service
|
||||
require.NoError(t, state.EnsureRegistration(10, &structs.RegisterRequest{
|
||||
|
|
|
@ -2782,6 +2782,10 @@ func TestInternal_PeeredUpstreams(t *testing.T) {
|
|||
t.Skip("too slow for testing.Short")
|
||||
}
|
||||
|
||||
orig := virtualIPVersionCheckInterval
|
||||
virtualIPVersionCheckInterval = 50 * time.Millisecond
|
||||
t.Cleanup(func() { virtualIPVersionCheckInterval = orig })
|
||||
|
||||
t.Parallel()
|
||||
_, s1 := testServerWithConfig(t)
|
||||
|
||||
|
|
Loading…
Reference in New Issue