Skip to content

Commit 5122fa7

Browse files
committed
wait rate limit in tests
1 parent 7e13ad5 commit 5122fa7

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pallets/subtensor/src/tests/swap_hotkey.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1264,6 +1264,8 @@ fn test_swap_parent_hotkey_childkey_maps() {
12641264

12651265
// Set child and verify state maps
12661266
mock_set_children(&coldkey, &parent_old, netuid, &[(u64::MAX, child)]);
1267+
// Wait rate limit
1268+
step_rate_limit(&TransactionType::SetChildren, netuid);
12671269
// Schedule some pending child keys.
12681270
mock_schedule_children(&coldkey, &parent_old, netuid, &[(u64::MAX, child_other)]);
12691271

@@ -1317,6 +1319,8 @@ fn test_swap_child_hotkey_childkey_maps() {
13171319

13181320
// Set child and verify state maps
13191321
mock_set_children(&coldkey, &parent, netuid, &[(u64::MAX, child_old)]);
1322+
// Wait rate limit
1323+
step_rate_limit(&TransactionType::SetChildren, netuid);
13201324
// Schedule some pending child keys.
13211325
mock_schedule_children(&coldkey, &parent, netuid, &[(u64::MAX, child_old)]);
13221326

0 commit comments

Comments
 (0)