Skip to content

Commit 2534e66

Browse files
committed
fix test errors
1 parent 555b64f commit 2534e66

File tree

6 files changed

+232
-217
lines changed

6 files changed

+232
-217
lines changed

src/tests/caretaker/test_caretaker.cairo

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ mod test_caretaker {
114114

115115
// assert that protocol owned yangs have been rebased
116116
let mut expected_after_yang_total_amts: Span<Wad> = expected_after_yang_total_amts.span();
117-
for yang in yangs_copy {
117+
for yang in yangs {
118118
assert(shrine.get_protocol_owned_yang_amt(*yang).is_zero(), 'yang not rebased');
119119

120120
let after_yang_total_amt: Wad = shrine.get_yang_total(*yang);

src/tests/common.cairo

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -324,6 +324,8 @@ pub fn get_token_balances(tokens: Span<ContractAddress>, addresses: Span<Contrac
324324
}
325325
balances.append(yang_balances.span());
326326
}
327+
328+
balances.span()
327329
}
328330

329331
// Fetches the ERC20 asset balance of a given address, and
@@ -352,8 +354,8 @@ pub fn assert_asset_balances_equalish(a: Span<AssetBalance>, mut b: Span<AssetBa
352354

353355
for i in a {
354356
let b: AssetBalance = *b.pop_front().unwrap();
355-
assert(*a.address == b.address, 'wrong asset address');
356-
assert_equalish(*a.amount, b.amount, error, message);
357+
assert(*i.address == b.address, 'wrong asset address');
358+
assert_equalish(*i.amount, b.amount, error, message);
357359
}
358360
}
359361

0 commit comments

Comments
 (0)