Fix failing tests
This commit is contained in:
parent
32907b59b2
commit
5aa8492315
|
@ -63,7 +63,7 @@ func TestIdentityImage_MarshalJSON(t *testing.T) {
|
|||
FileSize: 256,
|
||||
ResizeTarget: 80,
|
||||
}
|
||||
expected := `{"type":"thumbnail","uri":"data:image/jpeg;base64,/9j/2wCEAFA3PEY8MlA=","width":80,"height":80,"file_size":256,"resize_target":80}`
|
||||
expected := `{"key_uid":"","type":"thumbnail","uri":"data:image/jpeg;base64,/9j/2wCEAFA3PEY8MlA=","width":80,"height":80,"file_size":256,"resize_target":80}`
|
||||
|
||||
js, err := json.Marshal(ii)
|
||||
require.NoError(t, err)
|
||||
|
|
|
@ -3,6 +3,8 @@ package protocol
|
|||
import (
|
||||
"context"
|
||||
"crypto/ecdsa"
|
||||
"github.com/status-im/status-go/multiaccounts"
|
||||
"io/ioutil"
|
||||
"testing"
|
||||
|
||||
"github.com/google/uuid"
|
||||
|
@ -53,10 +55,16 @@ func (s *MessengerEmojiSuite) TearDownTest() {
|
|||
}
|
||||
|
||||
func (s *MessengerEmojiSuite) newMessengerWithKey(shh types.Waku, privateKey *ecdsa.PrivateKey) *Messenger {
|
||||
tmpfile, err := ioutil.TempFile("", "accounts-tests-")
|
||||
s.Require().NoError(err)
|
||||
madb, err := multiaccounts.InitializeDB(tmpfile.Name())
|
||||
s.Require().NoError(err)
|
||||
|
||||
options := []Option{
|
||||
WithCustomLogger(s.logger),
|
||||
WithMessagesPersistenceEnabled(),
|
||||
WithDatabaseConfig(sqlite.InMemoryPath, "some-key"),
|
||||
WithMultiAccounts(madb),
|
||||
WithDatasync(),
|
||||
}
|
||||
installationID := uuid.New().String()
|
||||
|
|
Loading…
Reference in New Issue