Skip to content

Commit 7c3522f

Browse files
committed
fix: integration test and document
1 parent 7044e36 commit 7c3522f

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

integration-tests/src/withdraw_all.rs

+3
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,9 @@ async fn withdraw_all() -> Result<()> {
5959

6060
context.fast_forward_minutes(6).await?;
6161

62+
// 3 calls to fully claim 210 jars
63+
context.sweat_jar().claim_total(None).with_user(&alice).await?;
64+
context.sweat_jar().claim_total(None).with_user(&alice).await?;
6265
context.sweat_jar().claim_total(None).with_user(&alice).await?;
6366

6467
let alice_balance = context.ft_contract().ft_balance_of(alice.to_near()).await?;

model/src/api.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,9 @@ pub trait InitApi {
2727
/// The `ClaimApi` trait defines methods for claiming interest from jars within the smart contract.
2828
#[make_integration_version]
2929
pub trait ClaimApi {
30-
/// Claims all available interest from all deposit jars belonging to the calling account.
30+
/// Claims available interest from up to 100 jars with the most interest for the calling account.
31+
/// If the calling account has more than 100 jars, the user will need to call this method multiple times
32+
/// to claim interest from all jars.
3133
///
3234
/// * `detailed` – An optional boolean value specifying if the method must return only total amount of claimed tokens
3335
/// or detailed summary for each claimed jar. Set it `true` to get a detailed result. In case of `false`

0 commit comments

Comments
 (0)