fix: missing fields in Communtiy CreateDeepCopy (#4718)

This commit is contained in:
Igor Sirotin 2024-02-12 23:26:32 +00:00 committed by GitHub
parent 432bfeea2f
commit 5e905518aa
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 9 additions and 0 deletions

View File

@ -2127,11 +2127,14 @@ func (o *Community) CreateDeepCopy() *Community {
Verified: o.config.Verified,
Spectated: o.config.Spectated,
Muted: o.config.Muted,
MuteTill: o.config.MuteTill,
Logger: o.config.Logger,
RequestedToJoinAt: o.config.RequestedToJoinAt,
RequestsToJoin: o.config.RequestsToJoin,
MemberIdentity: o.config.MemberIdentity,
EventsData: o.config.EventsData,
Shard: o.config.Shard,
PubsubTopicPrivateKey: o.config.PubsubTopicPrivateKey,
LastOpenedAt: o.config.LastOpenedAt,
},
timesource: o.timesource,

View File

@ -642,9 +642,15 @@ func (s *MessengerStoreNodeRequestSuite) TestRequestShardAndCommunityInfo() {
Shard: expectedShard,
}
shardTopic := transport.CommunityShardInfoTopic(community.IDString())
contentContentTopic := wakuV2common.BytesToTopic(transport.ToTopic(shardTopic))
storeNodeSubscription := s.setupStoreNodeEnvelopesWatcher(&contentContentTopic)
_, err := s.owner.SetCommunityShard(shardRequest)
s.Require().NoError(err)
s.waitForEnvelopes(storeNodeSubscription, 1)
s.waitForAvailableStoreNode(s.bob)
communityShard := community.CommunityShard()