vault/sdk/physical/inmem/inmem_ha_test.go
Hamid Ghaf e55c18ed12
adding copyright header (#19555)
* adding copyright header

* fix fmt and a test
2023-03-15 09:00:52 -07:00

25 lines
539 B
Go

// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: MPL-2.0
package inmem
import (
"testing"
log "github.com/hashicorp/go-hclog"
"github.com/hashicorp/vault/sdk/helper/logging"
"github.com/hashicorp/vault/sdk/physical"
)
func TestInmemHA(t *testing.T) {
logger := logging.NewVaultLogger(log.Debug)
inm, err := NewInmemHA(nil, logger)
if err != nil {
t.Fatal(err)
}
// Use the same inmem backend to acquire the same set of locks
physical.ExerciseHABackend(t, inm.(physical.HABackend), inm.(physical.HABackend))
}