continuous-integration/drone Build is failing
Migrate the workspace to React and Ant Design, improve account forms and responsive layouts, support outbound diagnostics and SSH fingerprint confirmation, and persist the management startup port. Preserve database migrations, remove S3 settings storage, and improve gateway audit handling.
24 lines
474 B
Go
24 lines
474 B
Go
package store
|
|
|
|
import (
|
|
"bytes"
|
|
"encoding/base64"
|
|
"linkport/internal/security"
|
|
"path/filepath"
|
|
"testing"
|
|
)
|
|
|
|
func outboundTestStore(t *testing.T) (*Store, string, *security.Vault) {
|
|
t.Helper()
|
|
path := filepath.Join(t.TempDir(), "linkport.sqlite")
|
|
vault, err := security.NewVault(base64.StdEncoding.EncodeToString(bytes.Repeat([]byte{3}, 32)))
|
|
if err != nil {
|
|
t.Fatal(err)
|
|
}
|
|
s, err := Open(path, vault)
|
|
if err != nil {
|
|
t.Fatal(err)
|
|
}
|
|
return s, path, vault
|
|
}
|