forked from cosmos/interchain-security
-
Notifications
You must be signed in to change notification settings - Fork 1
/
action_rapid_test.go
524 lines (473 loc) · 18.3 KB
/
action_rapid_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
package main
import (
"encoding/json"
"fmt"
"testing"
"time"
"github.com/google/go-cmp/cmp"
"github.com/stretchr/testify/require"
"pgregory.net/rapid"
)
// This file contains tests for serialization/deserialization of actions.
// The tests are written using the rapid testing library, which allows us to
// generate arbitrary actions and test that they can be serialized and
// deserialized without error.
// The generators for the various actions are defined in this file, and
// essentially tell rapid how to build these actions.
func TestActionMarshalling(t *testing.T) {
rapid.Check(t, func(t *rapid.T) {
action := GetActionGen().Draw(t, "Action")
err := MarshalAndUnmarshalAction(action)
if err != nil {
t.Fatalf("error marshalling and unmarshalling action: %v", err)
}
})
}
func MarshalAndUnmarshalAction(action interface{}) error {
// wraps the action with a step, since it needs custom unmarshalling that is called by the step unmarshaller
step := Step{
Action: action,
}
jsonobj, err := json.Marshal(step)
if err != nil {
return fmt.Errorf("error marshalling action inside step: %v", err)
}
var got Step
err = json.Unmarshal(jsonobj, &got)
if err != nil {
return fmt.Errorf("error unmarshalling action inside step: %v", err)
}
diff := cmp.Diff(step, got)
if diff != "" {
return fmt.Errorf("got (-), want (+): %v", diff)
}
return nil
}
// This needs to be adjusted manually when new actions are added and should
// include generators for all actions that are mentioned in main.go/runStep.
func GetActionGen() *rapid.Generator[any] {
return rapid.OneOf(
GetStartSovereignChainActionGen().AsAny(),
GetSubmitLegacyUpgradeProposalActionGen().AsAny(),
GetWaitUntilBlockActionGen().AsAny(),
GetChangeoverChainActionGen().AsAny(),
GetSendTokensActionGen().AsAny(),
GetStartChainActionGen().AsAny(),
GetSubmitTextProposalActionGen().AsAny(),
GetSubmitConsumerAdditionProposalActionGen().AsAny(),
GetSubmitConsumerRemovalProposalActionGen().AsAny(),
GetSubmitParamChangeProposalActionGen().AsAny(),
GetVoteGovProposalActionGen().AsAny(),
GetStartConsumerChainActionGen().AsAny(),
GetAddChainToRelayerActionGen().AsAny(),
GetAddIbcConnectionActionGen().AsAny(),
GetAddIbcChannelActionGen().AsAny(),
GetStartRelayerActionGen().AsAny(),
GetTransferChannelCompleteActionGen().AsAny(),
GetRelayPacketsActionGen().AsAny(),
GetRelayRewardPacketsToProviderActionGen().AsAny(),
GetDelegateTokensActionGen().AsAny(),
GetUnbondTokensActionGen().AsAny(),
GetRedelegateTokensActionGen().AsAny(),
GetDowntimeSlashActionGen().AsAny(),
GetUnjailValidatorActionGen().AsAny(),
GetRegisterRepresentativeActionGen().AsAny(),
GetDoublesignSlashActionGen().AsAny(),
GetAssignConsumerPubKeyActionGen().AsAny(),
GetCreateIbcClientsActionGen().AsAny(),
GetSlashMeterReplenishmentAction().AsAny(),
GetWaitTimeAction().AsAny(),
CreateCancelUnbondTokensActionGen().AsAny(),
CreateLightClientEquivocationAttackActionGen().AsAny(),
CreateLightClientAmnesiaAttackActionGen().AsAny(),
CreateLightClientLunaticAttackActionGen().AsAny(),
GetDetectConsumerEvidenceActionGen().AsAny(),
GetForkConsumerChainActionGen().AsAny(),
GetUpdateLightClientActionGen().AsAny(),
)
}
func CreateSubmitChangeRewardDenomsProposalActionGen() *rapid.Generator[SubmitChangeRewardDenomsProposalAction] {
return rapid.Custom(func(t *rapid.T) SubmitChangeRewardDenomsProposalAction {
return SubmitChangeRewardDenomsProposalAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
From: GetValidatorIDGen().Draw(t, "From"),
Deposit: rapid.Uint().Draw(t, "Deposit"),
Denoms: rapid.SliceOf(rapid.String()).Draw(t, "Denoms"),
}
})
}
func CreateLightClientEquivocationAttackActionGen() *rapid.Generator[LightClientEquivocationAttackAction] {
return rapid.Custom(func(t *rapid.T) LightClientEquivocationAttackAction {
return LightClientEquivocationAttackAction{
Validator: GetValidatorIDGen().Draw(t, "Validator"),
Chain: GetChainIDGen().Draw(t, "Chain"),
}
})
}
func CreateLightClientAmnesiaAttackActionGen() *rapid.Generator[LightClientAmnesiaAttackAction] {
return rapid.Custom(func(t *rapid.T) LightClientAmnesiaAttackAction {
return LightClientAmnesiaAttackAction{
Validator: GetValidatorIDGen().Draw(t, "Validator"),
Chain: GetChainIDGen().Draw(t, "Chain"),
}
})
}
func CreateLightClientLunaticAttackActionGen() *rapid.Generator[LightClientLunaticAttackAction] {
return rapid.Custom(func(t *rapid.T) LightClientLunaticAttackAction {
return LightClientLunaticAttackAction{
Validator: GetValidatorIDGen().Draw(t, "Validator"),
Chain: GetChainIDGen().Draw(t, "Chain"),
}
})
}
func CreateCancelUnbondTokensActionGen() *rapid.Generator[CancelUnbondTokensAction] {
return rapid.Custom(func(t *rapid.T) CancelUnbondTokensAction {
return CancelUnbondTokensAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Amount: rapid.Uint().Draw(t, "Amount"),
Delegator: GetValidatorIDGen().Draw(t, "Delegator"),
Validator: GetValidatorIDGen().Draw(t, "Validator"),
}
})
}
func GetCreateIbcClientsActionGen() *rapid.Generator[CreateIbcClientsAction] {
return rapid.Custom(func(t *rapid.T) CreateIbcClientsAction {
return CreateIbcClientsAction{
ChainA: GetChainIDGen().Draw(t, "ChainA"),
ChainB: GetChainIDGen().Draw(t, "ChainB"),
}
})
}
func GetStartSovereignChainActionGen() *rapid.Generator[StartSovereignChainAction] {
return rapid.Custom(func(t *rapid.T) StartSovereignChainAction {
return StartSovereignChainAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Validators: GetStartChainValidatorsGen().Draw(t, "Validators"),
GenesisChanges: rapid.String().Draw(t, "GenesisChanges"),
}
})
}
func GetSubmitLegacyUpgradeProposalActionGen() *rapid.Generator[UpgradeProposalAction] {
return rapid.Custom(func(t *rapid.T) UpgradeProposalAction {
return UpgradeProposalAction{
ChainID: GetChainIDGen().Draw(t, "ChainID"),
UpgradeTitle: rapid.String().Draw(t, "UpgradeTitle"),
Proposer: GetValidatorIDGen().Draw(t, "Proposer"),
UpgradeHeight: rapid.Uint64().Draw(t, "UpgradeHeight"),
}
})
}
func GetWaitUntilBlockActionGen() *rapid.Generator[WaitUntilBlockAction] {
return rapid.Custom(func(t *rapid.T) WaitUntilBlockAction {
return WaitUntilBlockAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Block: rapid.Uint().Draw(t, "Block"),
}
})
}
func GetChangeoverChainActionGen() *rapid.Generator[ChangeoverChainAction] {
return rapid.Custom(func(t *rapid.T) ChangeoverChainAction {
return ChangeoverChainAction{
SovereignChain: GetChainIDGen().Draw(t, "SovereignChain"),
ProviderChain: GetChainIDGen().Draw(t, "ProviderChain"),
Validators: GetStartChainValidatorsGen().Draw(t, "Validators"),
GenesisChanges: rapid.String().Draw(t, "GenesisChanges"),
}
})
}
func GetSendTokensActionGen() *rapid.Generator[SendTokensAction] {
return rapid.Custom(func(t *rapid.T) SendTokensAction {
return SendTokensAction{
Amount: rapid.Uint().Draw(t, "Amount"),
Chain: GetChainIDGen().Draw(t, "Chain"),
From: GetValidatorIDGen().Draw(t, "From"),
To: GetValidatorIDGen().Draw(t, "To"),
}
})
}
func GetStartChainActionGen() *rapid.Generator[StartChainAction] {
return rapid.Custom(func(t *rapid.T) StartChainAction {
return StartChainAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Validators: GetStartChainValidatorsGen().Draw(t, "Validators"),
GenesisChanges: rapid.String().Draw(t, "GenesisChanges"),
IsConsumer: rapid.Bool().Draw(t, "IsConsumer"),
}
})
}
func GetStartChainValidatorsGen() *rapid.Generator[[]StartChainValidator] {
return rapid.Custom(func(t *rapid.T) []StartChainValidator {
return rapid.SliceOf(GetStartChainValidatorGen()).Draw(t, "StartChainValidators")
})
}
func GetStartChainValidatorGen() *rapid.Generator[StartChainValidator] {
return rapid.Custom(func(t *rapid.T) StartChainValidator {
return StartChainValidator{
Id: GetValidatorIDGen().Draw(t, "Id"),
Allocation: rapid.Uint().Draw(t, "Allocation"),
Stake: rapid.Uint().Draw(t, "Stake"),
}
})
}
func GetSubmitTextProposalActionGen() *rapid.Generator[SubmitTextProposalAction] {
return rapid.Custom(func(t *rapid.T) SubmitTextProposalAction {
return SubmitTextProposalAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
From: GetValidatorIDGen().Draw(t, "From"),
Deposit: rapid.Uint().Draw(t, "Deposit"),
Title: rapid.String().Draw(t, "Title"),
Description: rapid.String().Draw(t, "Description"),
}
})
}
func GetSubmitConsumerAdditionProposalActionGen() *rapid.Generator[SubmitConsumerAdditionProposalAction] {
return rapid.Custom(func(t *rapid.T) SubmitConsumerAdditionProposalAction {
return SubmitConsumerAdditionProposalAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
From: GetValidatorIDGen().Draw(t, "From"),
Deposit: rapid.Uint().Draw(t, "Deposit"),
ConsumerChain: GetChainIDGen().Draw(t, "ConsumerChain"),
SpawnTime: rapid.Uint().Draw(t, "SpawnTime"),
InitialHeight: GetHeightGen().Draw(t, "InitialHeight"),
}
})
}
func GetSubmitConsumerRemovalProposalActionGen() *rapid.Generator[SubmitConsumerRemovalProposalAction] {
return rapid.Custom(func(t *rapid.T) SubmitConsumerRemovalProposalAction {
return SubmitConsumerRemovalProposalAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
From: GetValidatorIDGen().Draw(t, "From"),
Deposit: rapid.Uint().Draw(t, "Deposit"),
ConsumerChain: GetChainIDGen().Draw(t, "ConsumerChain"),
}
})
}
func GetSubmitParamChangeProposalActionGen() *rapid.Generator[SubmitEnableTransfersProposalAction] {
return rapid.Custom(func(t *rapid.T) SubmitEnableTransfersProposalAction {
return SubmitEnableTransfersProposalAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
From: GetValidatorIDGen().Draw(t, "From"),
Deposit: rapid.Uint().Draw(t, "Deposit"),
}
})
}
func TestMarshalAndUnmarshalTime(t *testing.T) {
rapid.Check(t, func(t *rapid.T) {
time1 := GetTimeGen().Draw(t, "time")
data, err := time1.MarshalJSON()
require.NoError(t, err)
var time2 time.Time
err = time2.UnmarshalJSON(data)
require.NoError(t, err)
require.True(t, time1.Equal(time2))
})
}
func GetTimeGen() *rapid.Generator[time.Time] {
return rapid.Custom(func(t *rapid.T) time.Time {
return time.Unix(rapid.Int64Range(-5.9959e+10, 1.5779e+11).Draw(t, "unix time"), 0).UTC()
})
}
func GetVoteGovProposalActionGen() *rapid.Generator[VoteGovProposalAction] {
return rapid.Custom(func(t *rapid.T) VoteGovProposalAction {
return VoteGovProposalAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
From: rapid.SliceOf(GetValidatorIDGen()).Draw(t, "From"),
Vote: rapid.SliceOf(rapid.String()).Draw(t, "Vote"),
PropNumber: rapid.Uint().Draw(t, "PropNumber"),
}
})
}
func GetStartConsumerChainActionGen() *rapid.Generator[StartConsumerChainAction] {
return rapid.Custom(func(t *rapid.T) StartConsumerChainAction {
return StartConsumerChainAction{
ConsumerChain: GetChainIDGen().Draw(t, "ConsumerChain"),
ProviderChain: GetChainIDGen().Draw(t, "ProviderChain"),
Validators: GetStartChainValidatorsGen().Draw(t, "Validators"),
GenesisChanges: rapid.String().Draw(t, "GenesisChanges"),
}
})
}
func GetAddChainToRelayerActionGen() *rapid.Generator[AddChainToRelayerAction] {
return rapid.Custom(func(t *rapid.T) AddChainToRelayerAction {
return AddChainToRelayerAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Validator: GetValidatorIDGen().Draw(t, "Validator"),
}
})
}
func GetAddIbcConnectionActionGen() *rapid.Generator[AddIbcConnectionAction] {
return rapid.Custom(func(t *rapid.T) AddIbcConnectionAction {
return AddIbcConnectionAction{
ChainA: GetChainIDGen().Draw(t, "ChainA"),
ChainB: GetChainIDGen().Draw(t, "ChainB"),
ClientA: rapid.Uint().Draw(t, "ClientA"),
ClientB: rapid.Uint().Draw(t, "ClientB"),
}
})
}
func GetAddIbcChannelActionGen() *rapid.Generator[AddIbcChannelAction] {
return rapid.Custom(func(t *rapid.T) AddIbcChannelAction {
return AddIbcChannelAction{
ChainA: GetChainIDGen().Draw(t, "ChainA"),
ChainB: GetChainIDGen().Draw(t, "ChainB"),
ConnectionA: rapid.Uint().Draw(t, "ConnectionA"),
PortA: rapid.String().Draw(t, "PortA"),
PortB: rapid.String().Draw(t, "PortB"),
Order: rapid.String().Draw(t, "Order"),
}
})
}
func GetStartRelayerActionGen() *rapid.Generator[StartRelayerAction] {
return rapid.Just(StartRelayerAction{})
}
func GetTransferChannelCompleteActionGen() *rapid.Generator[TransferChannelCompleteAction] {
return rapid.Custom(func(t *rapid.T) TransferChannelCompleteAction {
return TransferChannelCompleteAction{
ChainA: GetChainIDGen().Draw(t, "ChainA"),
ChainB: GetChainIDGen().Draw(t, "ChainB"),
ConnectionA: rapid.Uint().Draw(t, "ConnectionA"),
PortA: rapid.String().Draw(t, "PortA"),
PortB: rapid.String().Draw(t, "PortB"),
Order: rapid.String().Draw(t, "Order"),
ChannelA: rapid.Uint().Draw(t, "ChannelA"),
ChannelB: rapid.Uint().Draw(t, "ChannelB"),
}
})
}
func GetRelayPacketsActionGen() *rapid.Generator[RelayPacketsAction] {
return rapid.Custom(func(t *rapid.T) RelayPacketsAction {
return RelayPacketsAction{
ChainA: GetChainIDGen().Draw(t, "Chain"),
ChainB: GetChainIDGen().Draw(t, "Chain"),
Port: rapid.String().Draw(t, "Port"),
Channel: rapid.Uint().Draw(t, "Channel"),
}
})
}
func GetRelayRewardPacketsToProviderActionGen() *rapid.Generator[RelayRewardPacketsToProviderAction] {
return rapid.Custom(func(t *rapid.T) RelayRewardPacketsToProviderAction {
return RelayRewardPacketsToProviderAction{
ConsumerChain: GetChainIDGen().Draw(t, "ConsumerChain"),
ProviderChain: GetChainIDGen().Draw(t, "ProviderChain"),
Port: rapid.String().Draw(t, "Port"),
Channel: rapid.Uint().Draw(t, "Channel"),
}
})
}
func GetDelegateTokensActionGen() *rapid.Generator[DelegateTokensAction] {
return rapid.Custom(func(t *rapid.T) DelegateTokensAction {
return DelegateTokensAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Amount: rapid.Uint().Draw(t, "Amount"),
From: GetValidatorIDGen().Draw(t, "From"),
To: GetValidatorIDGen().Draw(t, "To"),
}
})
}
func GetUnbondTokensActionGen() *rapid.Generator[UnbondTokensAction] {
return rapid.Custom(func(t *rapid.T) UnbondTokensAction {
return UnbondTokensAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Amount: rapid.Uint().Draw(t, "Amount"),
Sender: GetValidatorIDGen().Draw(t, "Sender"),
UnbondFrom: GetValidatorIDGen().Draw(t, "UnbondFrom"),
}
})
}
func GetRedelegateTokensActionGen() *rapid.Generator[RedelegateTokensAction] {
return rapid.Custom(func(t *rapid.T) RedelegateTokensAction {
return RedelegateTokensAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Amount: rapid.Uint().Draw(t, "Amount"),
Src: GetValidatorIDGen().Draw(t, "Src"),
Dst: GetValidatorIDGen().Draw(t, "Dst"),
TxSender: GetValidatorIDGen().Draw(t, "TxSender"),
}
})
}
func GetDowntimeSlashActionGen() *rapid.Generator[DowntimeSlashAction] {
return rapid.Custom(func(t *rapid.T) DowntimeSlashAction {
return DowntimeSlashAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Validator: GetValidatorIDGen().Draw(t, "Validator"),
}
})
}
func GetUnjailValidatorActionGen() *rapid.Generator[UnjailValidatorAction] {
return rapid.Custom(func(t *rapid.T) UnjailValidatorAction {
return UnjailValidatorAction{
Validator: GetValidatorIDGen().Draw(t, "Validator"),
Provider: GetChainIDGen().Draw(t, "Provider"),
}
})
}
func GetRegisterRepresentativeActionGen() *rapid.Generator[RegisterRepresentativeAction] {
return rapid.Custom(func(t *rapid.T) RegisterRepresentativeAction {
return RegisterRepresentativeAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Representatives: rapid.SliceOf(GetValidatorIDGen()).Draw(t, "Representatives"),
Stakes: rapid.SliceOf(rapid.Uint()).Draw(t, "Stakes"),
}
})
}
func GetDoublesignSlashActionGen() *rapid.Generator[DoublesignSlashAction] {
return rapid.Custom(func(t *rapid.T) DoublesignSlashAction {
return DoublesignSlashAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Validator: GetValidatorIDGen().Draw(t, "Validator"),
}
})
}
func GetAssignConsumerPubKeyActionGen() *rapid.Generator[AssignConsumerPubKeyAction] {
return rapid.Custom(func(t *rapid.T) AssignConsumerPubKeyAction {
return AssignConsumerPubKeyAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
Validator: GetValidatorIDGen().Draw(t, "Validator"),
ConsumerPubkey: rapid.String().Draw(t, "ConsumerPubkey"),
ReconfigureNode: rapid.Bool().Draw(t, "ReconfigureNode"),
ExpectError: rapid.Bool().Draw(t, "ExpectError"),
}
})
}
func GetSlashMeterReplenishmentAction() *rapid.Generator[SlashMeterReplenishmentAction] {
return rapid.Custom(func(t *rapid.T) SlashMeterReplenishmentAction {
return SlashMeterReplenishmentAction{
TargetValue: rapid.Int64().Draw(t, "TargetValue"),
Timeout: time.Duration(rapid.Int().Draw(t, "Timeout")) * time.Millisecond,
}
})
}
func GetWaitTimeAction() *rapid.Generator[WaitTimeAction] {
return rapid.Custom(func(t *rapid.T) WaitTimeAction {
return WaitTimeAction{
WaitTime: time.Duration(rapid.Int().Draw(t, "Timeout")) * time.Millisecond,
}
})
}
func GetForkConsumerChainActionGen() *rapid.Generator[ForkConsumerChainAction] {
return rapid.Custom(func(t *rapid.T) ForkConsumerChainAction {
return ForkConsumerChainAction{
ConsumerChain: GetChainIDGen().Draw(t, "ConsumerChain"),
ProviderChain: GetChainIDGen().Draw(t, "ProviderChain"),
Validator: GetValidatorIDGen().Draw(t, "Validator"),
RelayerConfig: rapid.String().Draw(t, "RelayerConfig"),
}
})
}
func GetDetectConsumerEvidenceActionGen() *rapid.Generator[DetectConsumerEvidenceAction] {
return rapid.Custom(func(t *rapid.T) DetectConsumerEvidenceAction {
return DetectConsumerEvidenceAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
}
})
}
func GetUpdateLightClientActionGen() *rapid.Generator[UpdateLightClientAction] {
return rapid.Custom(func(t *rapid.T) UpdateLightClientAction {
return UpdateLightClientAction{
Chain: GetChainIDGen().Draw(t, "Chain"),
HostChain: GetChainIDGen().Draw(t, "HostChain"),
RelayerConfig: rapid.String().Draw(t, "RelayerConfig"),
ClientID: rapid.String().Draw(t, "ClientID"),
}
})
}