Skip to content
This repository has been archived by the owner on Aug 16, 2022. It is now read-only.

Commit

Permalink
fix: use hex encode instead of string cast
Browse files Browse the repository at this point in the history
Signed-off-by: KeisukeYamashita <[email protected]>
  • Loading branch information
KeisukeYamashita committed May 9, 2022
1 parent 6467524 commit 56a028d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion internal/infrastructure/mongo/mongo_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package mongo

import (
"context"
"encoding/hex"
"os"
"testing"
"time"
Expand Down Expand Up @@ -32,7 +33,7 @@ func connect(t *testing.T) func() (*mongodoc.Client, func()) {

return func() (*mongodoc.Client, func()) {
database, _ := uuid.New()
databaseName := "reearth-test-" + string(database[:])
databaseName := "reearth-test-" + hex.EncodeToString(database[:])
client := mongodoc.NewClient(databaseName, c)

return client, func() {
Expand Down

0 comments on commit 56a028d

Please sign in to comment.