working commit
This commit is contained in:
@@ -18,8 +18,8 @@ import (
|
||||
|
||||
"mstore/app/server"
|
||||
"mstore/pkg/client"
|
||||
"mstore/pkg/terms"
|
||||
"mstore/pkg/uuid"
|
||||
"mstore/pkg/term"
|
||||
"mstore/pkg/auxid"
|
||||
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
@@ -81,7 +81,7 @@ func TestAccountLife(t *testing.T) {
|
||||
username := "testuser"
|
||||
password := "testpass"
|
||||
|
||||
var accountID uuid.UUID
|
||||
var accountID uint64
|
||||
{
|
||||
// CreateAccount
|
||||
fmt.Printf("=== CreateAccount ===\n")
|
||||
@@ -92,7 +92,7 @@ func TestAccountLife(t *testing.T) {
|
||||
accountID, err = cli.CreateAccount(ctx, srvaddr, username, password)
|
||||
require.NoError(t, err)
|
||||
}
|
||||
var grantID uuid.UUID
|
||||
var grantID uint64
|
||||
{
|
||||
// CreateGrant
|
||||
fmt.Printf("=== CreateGrant ===\n")
|
||||
@@ -100,7 +100,7 @@ func TestAccountLife(t *testing.T) {
|
||||
ctx := context.Background()
|
||||
ctx, _ = context.WithTimeout(ctx, 1*time.Second)
|
||||
|
||||
grantID, err = cli.CreateGrantByAccountID(ctx, srvaddr, accountID, terms.RightReadAccounts, ".*")
|
||||
grantID, err = cli.CreateGrantByAccountID(ctx, srvaddr, accountID, term.RightReadAccounts, ".*")
|
||||
require.NoError(t, err)
|
||||
require.Equal(t, len(grantID), 36)
|
||||
}
|
||||
@@ -121,7 +121,7 @@ func TestAccountLife(t *testing.T) {
|
||||
ctx := context.Background()
|
||||
ctx, _ = context.WithTimeout(ctx, 1*time.Second)
|
||||
|
||||
grantID, err = cli.CreateGrantByAccountID(ctx, srvaddr, accountID, terms.RightWriteAccounts, ".*")
|
||||
grantID, err = cli.CreateGrantByAccountID(ctx, srvaddr, accountID, term.RightWriteAccounts, ".*")
|
||||
require.NoError(t, err)
|
||||
require.Equal(t, len(grantID), 36)
|
||||
fmt.Printf("grantID: %s\n", grantID)
|
||||
|
||||
Reference in New Issue
Block a user