Skip to content

Commit d0dbbf5

Browse files
Apply suggestions from code review
Co-authored-by: Taras Maliarchuk <maliarchuk@gmail.com>
1 parent fa054fd commit d0dbbf5

3 files changed

Lines changed: 6 additions & 6 deletions

File tree

cadence/tests/rebalance_edge_cases_test.cdc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -202,13 +202,13 @@ fun testRebalance_AsyncUpdate_ProcessesAtMostConfiguredBatchSize() {
202202
admin: PROTOCOL_ACCOUNT,
203203
signer: user,
204204
amount: 1_000.0,
205-
vaultStoragePath: /storage/flowTokenVault,
205+
vaultStoragePath: FLOW_VAULT_STORAGE_PATH,
206206
pushToDrawDownSink: true
207207
)
208208
pid = pid + 1
209209
}
210210

211-
// drop price: all positions overcollateralised
211+
// raise price: all positions overcollateralised
212212
// effectiveCollateral = 1000 × 1.2 × 0.8 = 960
213213
// effectiveDebt ≈ 615.38
214214
// health ≈ 1.56 > maxHealth (1.5)

cadence/tests/test_helpers.cdc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -866,7 +866,7 @@ fun withdrawStabilityFund(
866866
}
867867

868868
access(all)
869-
fun rebalancePosition(signer: Test.TestAccount, pid: UInt64, force: Bool): Test.TransactionResult{
869+
fun rebalancePosition(signer: Test.TestAccount, pid: UInt64, force: Bool): Test.TransactionResult {
870870
return _executeTransaction(
871871
"../transactions/flow-alp/pool-management/rebalance_position.cdc",
872872
[ pid, force ],
@@ -875,7 +875,7 @@ fun rebalancePosition(signer: Test.TestAccount, pid: UInt64, force: Bool): Test.
875875
}
876876

877877
access(all)
878-
fun setDrawDownSink(signer: Test.TestAccount, pid: UInt64, sink: {DeFiActions.Sink}?): Test.TransactionResult{
878+
fun setDrawDownSink(signer: Test.TestAccount, pid: UInt64, sink: {DeFiActions.Sink}?): Test.TransactionResult {
879879
return _executeTransaction(
880880
"./transactions/position-manager/set_draw_down_sink.cdc",
881881
[ pid, sink ],
@@ -1071,7 +1071,7 @@ fun withdrawReserve(
10711071
Test.expect(txRes, beFailed ? Test.beFailed() : Test.beSucceeded())
10721072
}
10731073

1074-
/// the async update queue so all queued positions are processed.
1074+
/// Drains the async update queue so all queued positions are processed.
10751075
access(all)
10761076
fun asyncUpdate(): Test.TransactionResult {
10771077
return _executeTransaction(

cadence/tests/transactions/position-manager/set_draw_down_sink.cdc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ transaction(
2626
}
2727

2828
execute {
29-
// Privide new sink for the position directly
29+
// Provide new sink for the position directly
3030
self.position.provideSink(sink: sink)
3131
}
3232
}

0 commit comments

Comments
 (0)