Skip to content

Commit

Permalink
Update client test
Browse files Browse the repository at this point in the history
  • Loading branch information
krapie committed Dec 2, 2023
1 parent 3ebef65 commit 745ad56
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 41 deletions.
61 changes: 25 additions & 36 deletions client/client_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//go:build amd64
//TODO(Krapie) go:build amd64

/*
* Copyright 2021 The Yorkie Authors. All rights reserved.
Expand All @@ -19,61 +19,51 @@
package client_test

import (
"connectrpc.com/connect"
"context"
"github.com/yorkie-team/yorkie/api/yorkie/v1/v1connect"
"net/http"
"net/http/httptest"
"reflect"
"testing"

"github.com/rs/xid"
"github.com/stretchr/testify/assert"
monkey "github.com/undefinedlabs/go-mpatch"
"golang.org/x/net/nettest"
"google.golang.org/grpc"
grpcmetadata "google.golang.org/grpc/metadata"

"github.com/yorkie-team/yorkie/api/types"
api "github.com/yorkie-team/yorkie/api/yorkie/v1"
"github.com/yorkie-team/yorkie/client"
)

type testYorkieServer struct {
grpcServer *grpc.Server
yorkieServer *api.UnimplementedYorkieServiceServer
httpServer *httptest.Server
yorkieServer *v1connect.UnimplementedYorkieServiceHandler
}

// dialTestYorkieServer creates a new instance of testYorkieServer and
// dials it with LocalListener.
func dialTestYorkieServer(t *testing.T) (*testYorkieServer, string) {
yorkieServer := &api.UnimplementedYorkieServiceServer{}
grpcServer := grpc.NewServer()
api.RegisterYorkieServiceServer(grpcServer, yorkieServer)
func dialTestYorkieServer() (*testYorkieServer, string) {
yorkieServer := &v1connect.UnimplementedYorkieServiceHandler{}
mux := http.NewServeMux()
mux.Handle(v1connect.NewYorkieServiceHandler(yorkieServer, nil))
httpServer := httptest.NewUnstartedServer(mux)

testYorkieServer := &testYorkieServer{
grpcServer: grpcServer,
httpServer: httpServer,
yorkieServer: yorkieServer,
}

return testYorkieServer, testYorkieServer.listenAndServe(t)
return testYorkieServer, testYorkieServer.listenAndServe()
}

func (s *testYorkieServer) listenAndServe(t *testing.T) string {
lis, err := nettest.NewLocalListener("tcp")
if err != nil {
t.Fatalf("failed to listen: %v", err)
}

go func() {
if err := s.grpcServer.Serve(lis); err != nil {
if err != grpc.ErrServerStopped {
t.Error(err)
}
}
}()
func (s *testYorkieServer) listenAndServe() string {
s.httpServer.Start()

return lis.Addr().String()
return s.httpServer.URL
}

func (s *testYorkieServer) Stop() {
s.grpcServer.Stop()
s.httpServer.Close()
}

func TestClient(t *testing.T) {
Expand All @@ -87,7 +77,7 @@ func TestClient(t *testing.T) {
t.Run("x-shard-key test", func(t *testing.T) {
dummyID := types.ID("000000000000000000000000")

testServer, addr := dialTestYorkieServer(t)
testServer, addr := dialTestYorkieServer()
defer testServer.Stop()

cli, err := client.Dial(addr, client.WithAPIKey("dummy-api-key"))
Expand All @@ -98,21 +88,20 @@ func TestClient(t *testing.T) {
reflect.TypeOf(testServer.yorkieServer),
"ActivateClient",
func(
m *api.UnimplementedYorkieServiceServer,
m *v1connect.UnimplementedYorkieServiceHandler,
ctx context.Context,
req *api.ActivateClientRequest,
) (*api.ActivateClientResponse, error) {
req *connect.Request[api.ActivateClientRequest],
) (*connect.Response[api.ActivateClientResponse], error) {
assert.NoError(t, patch.Unpatch())
defer func() {
assert.NoError(t, patch.Patch())
}()

data, _ := grpcmetadata.FromIncomingContext(ctx)
assert.Equal(t, "dummy-api-key", data[types.ShardKey][0])
assert.Equal(t, "dummy-api-key", req.Header().Get(types.ShardKey))

return &api.ActivateClientResponse{
return connect.NewResponse(&api.ActivateClientResponse{
ClientId: dummyID.String(),
}, nil
}), nil
},
)
assert.NoError(t, err)
Expand Down
5 changes: 4 additions & 1 deletion server/backend/database/change_info.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ import (
// ErrEncodeOperationFailed is returned when encoding operations failed.
var ErrEncodeOperationFailed = errors.New("encode operations failed")

// ErrDecodeOperationFailed is returned when decoding operations failed.
var ErrDecodeOperationFailed = errors.New("decode operations failed")

// ChangeInfo is a structure representing information of a change.
type ChangeInfo struct {
ID types.ID `bson:"_id"`
Expand Down Expand Up @@ -94,7 +97,7 @@ func (i *ChangeInfo) ToChange() (*change.Change, error) {
for _, bytesOp := range i.Operations {
pbOp := api.Operation{}
if err := proto.Unmarshal(bytesOp, &pbOp); err != nil {
return nil, err
return nil, ErrDecodeOperationFailed
}
pbOps = append(pbOps, &pbOp)
}
Expand Down
2 changes: 1 addition & 1 deletion server/packs/serverpacks.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ func (p *ServerPack) ToPBChangePack() (*api.ChangePack, error) {
for _, bytesOp := range info.Operations {
pbOp := api.Operation{}
if err := proto.Unmarshal(bytesOp, &pbOp); err != nil {
return nil, err
return nil, database.ErrDecodeOperationFailed
}
pbOps = append(pbOps, &pbOp)
}
Expand Down
2 changes: 1 addition & 1 deletion server/rpc/connecthelper/logging.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

// Package grpchelper provides helper functions for gRPC.
// Package connecthelper provides helper functions for gRPC.
package connecthelper

import (
Expand Down
12 changes: 10 additions & 2 deletions server/rpc/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ func NewServer(conf *Config, be *backend.Backend) (*Server, error) {

interceptor := connect.WithInterceptors(
connecthelper.NewLoggingInterceptor(),
// TODO(krapie): update prometehus metrics server to http server
// be.Metrics.ServerMetrics()
interceptors.NewAdminAuthInterceptor(be, tokenManager),
interceptors.NewContextInterceptor(be),
Expand Down Expand Up @@ -157,10 +158,17 @@ func (s *Server) listenAndServe() error {
func (s *Server) Shutdown(graceful bool) {
s.yorkieServiceCancel()

// TODO(krapie): find graceful way to shutdown http server
if graceful {
s.httpServer.Shutdown(context.Background())
err := s.httpServer.Shutdown(context.Background())
if err != nil {
return
}
} else {
s.httpServer.Shutdown(context.Background())
err := s.httpServer.Shutdown(context.Background())
if err != nil {
return
}
}
}

Expand Down

1 comment on commit 745ad56

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Go Benchmark

Benchmark suite Current: 745ad56 Previous: 3ebef65 Ratio
BenchmarkDocument/constructor_test - ns/op 1356 ns/op 1373 ns/op 0.99
BenchmarkDocument/constructor_test - B/op 1208 B/op 1208 B/op 1
BenchmarkDocument/constructor_test - allocs/op 20 allocs/op 20 allocs/op 1
BenchmarkDocument/status_test - ns/op 869.6 ns/op 796.5 ns/op 1.09
BenchmarkDocument/status_test - B/op 1176 B/op 1176 B/op 1
BenchmarkDocument/status_test - allocs/op 18 allocs/op 18 allocs/op 1
BenchmarkDocument/equals_test - ns/op 7740 ns/op 8302 ns/op 0.93
BenchmarkDocument/equals_test - B/op 6913 B/op 6913 B/op 1
BenchmarkDocument/equals_test - allocs/op 120 allocs/op 120 allocs/op 1
BenchmarkDocument/nested_update_test - ns/op 16023 ns/op 16598 ns/op 0.97
BenchmarkDocument/nested_update_test - B/op 11962 B/op 11962 B/op 1
BenchmarkDocument/nested_update_test - allocs/op 254 allocs/op 254 allocs/op 1
BenchmarkDocument/delete_test - ns/op 21791 ns/op 22626 ns/op 0.96
BenchmarkDocument/delete_test - B/op 15188 B/op 15188 B/op 1
BenchmarkDocument/delete_test - allocs/op 333 allocs/op 333 allocs/op 1
BenchmarkDocument/object_test - ns/op 8276 ns/op 8699 ns/op 0.95
BenchmarkDocument/object_test - B/op 6721 B/op 6721 B/op 1
BenchmarkDocument/object_test - allocs/op 116 allocs/op 116 allocs/op 1
BenchmarkDocument/array_test - ns/op 28476 ns/op 29401 ns/op 0.97
BenchmarkDocument/array_test - B/op 11819 B/op 11819 B/op 1
BenchmarkDocument/array_test - allocs/op 270 allocs/op 270 allocs/op 1
BenchmarkDocument/text_test - ns/op 30320 ns/op 31226 ns/op 0.97
BenchmarkDocument/text_test - B/op 14795 B/op 14795 B/op 1
BenchmarkDocument/text_test - allocs/op 468 allocs/op 468 allocs/op 1
BenchmarkDocument/text_composition_test - ns/op 28901 ns/op 29299 ns/op 0.99
BenchmarkDocument/text_composition_test - B/op 18278 B/op 18278 B/op 1
BenchmarkDocument/text_composition_test - allocs/op 477 allocs/op 477 allocs/op 1
BenchmarkDocument/rich_text_test - ns/op 79666 ns/op 82820 ns/op 0.96
BenchmarkDocument/rich_text_test - B/op 38540 B/op 38540 B/op 1
BenchmarkDocument/rich_text_test - allocs/op 1147 allocs/op 1147 allocs/op 1
BenchmarkDocument/counter_test - ns/op 16951 ns/op 17386 ns/op 0.97
BenchmarkDocument/counter_test - B/op 10210 B/op 10210 B/op 1
BenchmarkDocument/counter_test - allocs/op 236 allocs/op 236 allocs/op 1
BenchmarkDocument/text_edit_gc_100 - ns/op 2875009 ns/op 2970186 ns/op 0.97
BenchmarkDocument/text_edit_gc_100 - B/op 1655289 B/op 1655326 B/op 1.00
BenchmarkDocument/text_edit_gc_100 - allocs/op 17092 allocs/op 17093 allocs/op 1.00
BenchmarkDocument/text_edit_gc_1000 - ns/op 229524908 ns/op 231735416 ns/op 0.99
BenchmarkDocument/text_edit_gc_1000 - B/op 144342929 B/op 144366033 B/op 1.00
BenchmarkDocument/text_edit_gc_1000 - allocs/op 200912 allocs/op 201007 allocs/op 1.00
BenchmarkDocument/text_split_gc_100 - ns/op 3365441 ns/op 3385194 ns/op 0.99
BenchmarkDocument/text_split_gc_100 - B/op 2313541 B/op 2313331 B/op 1.00
BenchmarkDocument/text_split_gc_100 - allocs/op 16195 allocs/op 16194 allocs/op 1.00
BenchmarkDocument/text_split_gc_1000 - ns/op 287090704 ns/op 296761342 ns/op 0.97
BenchmarkDocument/text_split_gc_1000 - B/op 228900092 B/op 228881832 B/op 1.00
BenchmarkDocument/text_split_gc_1000 - allocs/op 203986 allocs/op 203904 allocs/op 1.00
BenchmarkDocument/text_delete_all_10000 - ns/op 11080080 ns/op 11146892 ns/op 0.99
BenchmarkDocument/text_delete_all_10000 - B/op 5810134 B/op 5810543 B/op 1.00
BenchmarkDocument/text_delete_all_10000 - allocs/op 40673 allocs/op 40675 allocs/op 1.00
BenchmarkDocument/text_delete_all_100000 - ns/op 199574760 ns/op 187188955 ns/op 1.07
BenchmarkDocument/text_delete_all_100000 - B/op 81908890 B/op 81887592 B/op 1.00
BenchmarkDocument/text_delete_all_100000 - allocs/op 411659 allocs/op 411550 allocs/op 1.00
BenchmarkDocument/text_100 - ns/op 232499 ns/op 232235 ns/op 1.00
BenchmarkDocument/text_100 - B/op 118483 B/op 118483 B/op 1
BenchmarkDocument/text_100 - allocs/op 5080 allocs/op 5080 allocs/op 1
BenchmarkDocument/text_1000 - ns/op 2518380 ns/op 2502773 ns/op 1.01
BenchmarkDocument/text_1000 - B/op 1153073 B/op 1153073 B/op 1
BenchmarkDocument/text_1000 - allocs/op 50084 allocs/op 50084 allocs/op 1
BenchmarkDocument/array_1000 - ns/op 1241969 ns/op 1267389 ns/op 0.98
BenchmarkDocument/array_1000 - B/op 1091226 B/op 1091268 B/op 1.00
BenchmarkDocument/array_1000 - allocs/op 11825 allocs/op 11826 allocs/op 1.00
BenchmarkDocument/array_10000 - ns/op 13374007 ns/op 13549731 ns/op 0.99
BenchmarkDocument/array_10000 - B/op 9799557 B/op 9800047 B/op 1.00
BenchmarkDocument/array_10000 - allocs/op 120290 allocs/op 120291 allocs/op 1.00
BenchmarkDocument/array_gc_100 - ns/op 153246 ns/op 153664 ns/op 1.00
BenchmarkDocument/array_gc_100 - B/op 132502 B/op 132498 B/op 1.00
BenchmarkDocument/array_gc_100 - allocs/op 1249 allocs/op 1248 allocs/op 1.00
BenchmarkDocument/array_gc_1000 - ns/op 1485983 ns/op 1451255 ns/op 1.02
BenchmarkDocument/array_gc_1000 - B/op 1158900 B/op 1158965 B/op 1.00
BenchmarkDocument/array_gc_1000 - allocs/op 12864 allocs/op 12865 allocs/op 1.00
BenchmarkDocument/counter_1000 - ns/op 218940 ns/op 215664 ns/op 1.02
BenchmarkDocument/counter_1000 - B/op 192854 B/op 192852 B/op 1.00
BenchmarkDocument/counter_1000 - allocs/op 5765 allocs/op 5765 allocs/op 1
BenchmarkDocument/counter_10000 - ns/op 2254703 ns/op 2222359 ns/op 1.01
BenchmarkDocument/counter_10000 - B/op 2087754 B/op 2087783 B/op 1.00
BenchmarkDocument/counter_10000 - allocs/op 59772 allocs/op 59772 allocs/op 1
BenchmarkDocument/object_1000 - ns/op 1427793 ns/op 1433455 ns/op 1.00
BenchmarkDocument/object_1000 - B/op 1428064 B/op 1427946 B/op 1.00
BenchmarkDocument/object_1000 - allocs/op 9845 allocs/op 9845 allocs/op 1
BenchmarkDocument/object_10000 - ns/op 14888965 ns/op 14878581 ns/op 1.00
BenchmarkDocument/object_10000 - B/op 12164956 B/op 12167003 B/op 1.00
BenchmarkDocument/object_10000 - allocs/op 100555 allocs/op 100561 allocs/op 1.00
BenchmarkDocument/tree_100 - ns/op 720516 ns/op 722947 ns/op 1.00
BenchmarkDocument/tree_100 - B/op 442889 B/op 442891 B/op 1.00
BenchmarkDocument/tree_100 - allocs/op 4506 allocs/op 4506 allocs/op 1
BenchmarkDocument/tree_1000 - ns/op 48663360 ns/op 48715965 ns/op 1.00
BenchmarkDocument/tree_1000 - B/op 35222160 B/op 35222566 B/op 1.00
BenchmarkDocument/tree_1000 - allocs/op 44118 allocs/op 44119 allocs/op 1.00
BenchmarkDocument/tree_10000 - ns/op 6536835076 ns/op 6243742972 ns/op 1.05
BenchmarkDocument/tree_10000 - B/op 3438872816 B/op 3439193776 B/op 1.00
BenchmarkDocument/tree_10000 - allocs/op 440190 allocs/op 440204 allocs/op 1.00
BenchmarkDocument/tree_delete_all_1000 - ns/op 49342354 ns/op 50492483 ns/op 0.98
BenchmarkDocument/tree_delete_all_1000 - B/op 35700738 B/op 35687345 B/op 1.00
BenchmarkDocument/tree_delete_all_1000 - allocs/op 51744 allocs/op 51744 allocs/op 1
BenchmarkDocument/tree_edit_gc_100 - ns/op 2708441 ns/op 2674319 ns/op 1.01
BenchmarkDocument/tree_edit_gc_100 - B/op 2099480 B/op 2099522 B/op 1.00
BenchmarkDocument/tree_edit_gc_100 - allocs/op 11165 allocs/op 11165 allocs/op 1
BenchmarkDocument/tree_edit_gc_1000 - ns/op 201700791 ns/op 200656697 ns/op 1.01
BenchmarkDocument/tree_edit_gc_1000 - B/op 180293018 B/op 180293307 B/op 1.00
BenchmarkDocument/tree_edit_gc_1000 - allocs/op 113362 allocs/op 113350 allocs/op 1.00
BenchmarkDocument/tree_split_gc_100 - ns/op 1944253 ns/op 1969140 ns/op 0.99
BenchmarkDocument/tree_split_gc_100 - B/op 1363457 B/op 1363475 B/op 1.00
BenchmarkDocument/tree_split_gc_100 - allocs/op 8735 allocs/op 8735 allocs/op 1
BenchmarkDocument/tree_split_gc_1000 - ns/op 132696602 ns/op 133034523 ns/op 1.00
BenchmarkDocument/tree_split_gc_1000 - B/op 120284972 B/op 120284053 B/op 1.00
BenchmarkDocument/tree_split_gc_1000 - allocs/op 96192 allocs/op 96193 allocs/op 1.00
BenchmarkRPC/client_to_server - ns/op 356791793 ns/op 356375965 ns/op 1.00
BenchmarkRPC/client_to_server - B/op 16347973 B/op 16323573 B/op 1.00
BenchmarkRPC/client_to_server - allocs/op 166468 allocs/op 165420 allocs/op 1.01
BenchmarkRPC/client_to_client_via_server - ns/op 611798466 ns/op 607723810 ns/op 1.01
BenchmarkRPC/client_to_client_via_server - B/op 36136892 B/op 34041892 B/op 1.06
BenchmarkRPC/client_to_client_via_server - allocs/op 311330 allocs/op 309871 allocs/op 1.00
BenchmarkRPC/attach_large_document - ns/op 1255271148 ns/op 1463602622 ns/op 0.86
BenchmarkRPC/attach_large_document - B/op 1889148032 B/op 1878647264 B/op 1.01
BenchmarkRPC/attach_large_document - allocs/op 7137 allocs/op 7043 allocs/op 1.01
BenchmarkRPC/adminCli_to_server - ns/op 538365170 ns/op 541741676 ns/op 0.99
BenchmarkRPC/adminCli_to_server - B/op 35598936 B/op 36380716 B/op 0.98
BenchmarkRPC/adminCli_to_server - allocs/op 285579 allocs/op 284616 allocs/op 1.00
BenchmarkLocker - ns/op 64.26 ns/op 65.29 ns/op 0.98
BenchmarkLocker - B/op 16 B/op 16 B/op 1
BenchmarkLocker - allocs/op 1 allocs/op 1 allocs/op 1
BenchmarkLockerParallel - ns/op 39.95 ns/op 38.64 ns/op 1.03
BenchmarkLockerParallel - B/op 0 B/op 0 B/op NaN
BenchmarkLockerParallel - allocs/op 0 allocs/op 0 allocs/op NaN
BenchmarkLockerMoreKeys - ns/op 140 ns/op 138.5 ns/op 1.01
BenchmarkLockerMoreKeys - B/op 15 B/op 15 B/op 1
BenchmarkLockerMoreKeys - allocs/op 0 allocs/op 0 allocs/op NaN
BenchmarkChange/Push_10_Changes - ns/op 3805377 ns/op 3779429 ns/op 1.01
BenchmarkChange/Push_10_Changes - B/op 125720 B/op 126275 B/op 1.00
BenchmarkChange/Push_10_Changes - allocs/op 1254 allocs/op 1254 allocs/op 1
BenchmarkChange/Push_100_Changes - ns/op 14075069 ns/op 14129092 ns/op 1.00
BenchmarkChange/Push_100_Changes - B/op 641875 B/op 646942 B/op 0.99
BenchmarkChange/Push_100_Changes - allocs/op 6538 allocs/op 6540 allocs/op 1.00
BenchmarkChange/Push_1000_Changes - ns/op 113166853 ns/op 113213707 ns/op 1.00
BenchmarkChange/Push_1000_Changes - B/op 6084627 B/op 6011043 B/op 1.01
BenchmarkChange/Push_1000_Changes - allocs/op 62156 allocs/op 62155 allocs/op 1.00
BenchmarkChange/Pull_10_Changes - ns/op 2854472 ns/op 2837624 ns/op 1.01
BenchmarkChange/Pull_10_Changes - B/op 100424 B/op 100327 B/op 1.00
BenchmarkChange/Pull_10_Changes - allocs/op 951 allocs/op 951 allocs/op 1
BenchmarkChange/Pull_100_Changes - ns/op 4356641 ns/op 4303014 ns/op 1.01
BenchmarkChange/Pull_100_Changes - B/op 257628 B/op 257269 B/op 1.00
BenchmarkChange/Pull_100_Changes - allocs/op 3154 allocs/op 3154 allocs/op 1
BenchmarkChange/Pull_1000_Changes - ns/op 8420616 ns/op 8473189 ns/op 0.99
BenchmarkChange/Pull_1000_Changes - B/op 1394364 B/op 1393414 B/op 1.00
BenchmarkChange/Pull_1000_Changes - allocs/op 26867 allocs/op 26869 allocs/op 1.00
BenchmarkSnapshot/Push_3KB_snapshot - ns/op 16867808 ns/op 16717315 ns/op 1.01
BenchmarkSnapshot/Push_3KB_snapshot - B/op 810117 B/op 807884 B/op 1.00
BenchmarkSnapshot/Push_3KB_snapshot - allocs/op 6541 allocs/op 6541 allocs/op 1
BenchmarkSnapshot/Push_30KB_snapshot - ns/op 118213323 ns/op 117501595 ns/op 1.01
BenchmarkSnapshot/Push_30KB_snapshot - B/op 6205390 B/op 6250940 B/op 0.99
BenchmarkSnapshot/Push_30KB_snapshot - allocs/op 62163 allocs/op 62161 allocs/op 1.00
BenchmarkSnapshot/Pull_3KB_snapshot - ns/op 6609866 ns/op 6521588 ns/op 1.01
BenchmarkSnapshot/Pull_3KB_snapshot - B/op 905032 B/op 904310 B/op 1.00
BenchmarkSnapshot/Pull_3KB_snapshot - allocs/op 14881 allocs/op 14878 allocs/op 1.00
BenchmarkSnapshot/Pull_30KB_snapshot - ns/op 14519021 ns/op 15228711 ns/op 0.95
BenchmarkSnapshot/Pull_30KB_snapshot - B/op 6982823 B/op 6983077 B/op 1.00
BenchmarkSnapshot/Pull_30KB_snapshot - allocs/op 144138 allocs/op 144141 allocs/op 1.00
BenchmarkSync/memory_sync_10_test - ns/op 6820 ns/op 6917 ns/op 0.99
BenchmarkSync/memory_sync_10_test - B/op 1286 B/op 1286 B/op 1
BenchmarkSync/memory_sync_10_test - allocs/op 38 allocs/op 38 allocs/op 1
BenchmarkSync/memory_sync_100_test - ns/op 51967 ns/op 51493 ns/op 1.01
BenchmarkSync/memory_sync_100_test - B/op 8646 B/op 8650 B/op 1.00
BenchmarkSync/memory_sync_100_test - allocs/op 273 allocs/op 273 allocs/op 1
BenchmarkSync/memory_sync_1000_test - ns/op 599715 ns/op 598451 ns/op 1.00
BenchmarkSync/memory_sync_1000_test - B/op 74418 B/op 74330 B/op 1.00
BenchmarkSync/memory_sync_1000_test - allocs/op 2114 allocs/op 2108 allocs/op 1.00
BenchmarkSync/memory_sync_10000_test - ns/op 7359086 ns/op 7141413 ns/op 1.03
BenchmarkSync/memory_sync_10000_test - B/op 760473 B/op 761330 B/op 1.00
BenchmarkSync/memory_sync_10000_test - allocs/op 20574 allocs/op 20560 allocs/op 1.00
BenchmarkTextEditing - ns/op 19022842184 ns/op 19117165431 ns/op 1.00
BenchmarkTextEditing - B/op 9037381864 B/op 9037584392 B/op 1.00
BenchmarkTextEditing - allocs/op 19920396 allocs/op 19921383 allocs/op 1.00

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.