Skip to content

Commit

Permalink
feat: update endpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
bucurdavid committed Mar 15, 2024
1 parent 82ce756 commit b0c1d0a
Show file tree
Hide file tree
Showing 3 changed files with 83 additions and 83 deletions.
158 changes: 79 additions & 79 deletions src/abis/core-mx-life-bonding-sc.abi.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
"type": "u64"
},
{
"name": "lock_period",
"name": "lock_period_seconds",
"type": "u64"
}
],
Expand Down Expand Up @@ -108,83 +108,6 @@
],
"outputs": []
},
{
"name": "getAcceptedCallers",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "variadic<Address>",
"multi_result": true
}
]
},
{
"name": "getBondPaymentToken",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "TokenIdentifier"
}
]
},
{
"name": "getLockPeriods",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "variadic<u64>",
"multi_result": true
}
]
},
{
"name": "getLockPeriodBondAmount",
"mutability": "readonly",
"inputs": [
{
"name": "lock_period",
"type": "u64"
}
],
"outputs": [
{
"type": "BigUint"
}
]
},
{
"name": "getMinimumPenalty",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "u64"
}
]
},
{
"name": "getMaximumPenalty",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "u64"
}
]
},
{
"name": "getWithdrawPenalty",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "u64"
}
]
},
{
"name": "getCompensationBlacklist",
"mutability": "readonly",
Expand Down Expand Up @@ -543,7 +466,7 @@
"outputs": []
},
{
"name": "setPeriodsBonds",
"name": "addPeriodsBonds",
"mutability": "mutable",
"inputs": [
{
Expand Down Expand Up @@ -630,6 +553,83 @@
"type": "Address"
}
]
},
{
"name": "getAcceptedCallers",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "variadic<Address>",
"multi_result": true
}
]
},
{
"name": "getBondPaymentToken",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "TokenIdentifier"
}
]
},
{
"name": "getLockPeriods",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "variadic<u64>",
"multi_result": true
}
]
},
{
"name": "getLockPeriodBondAmount",
"mutability": "readonly",
"inputs": [
{
"name": "lock_period",
"type": "u64"
}
],
"outputs": [
{
"type": "BigUint"
}
]
},
{
"name": "getMinimumPenalty",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "u64"
}
]
},
{
"name": "getMaximumPenalty",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "u64"
}
]
},
{
"name": "getWithdrawPenalty",
"mutability": "readonly",
"inputs": [],
"outputs": [
{
"type": "u64"
}
]
}
],
"events": [
Expand Down
6 changes: 3 additions & 3 deletions src/bond.ts
Original file line number Diff line number Diff line change
Expand Up @@ -807,12 +807,12 @@ export class BondContract extends Contract {
}

/**
* Builds a `setPeriodsBonds` transaction to set the periods and bonds
* Builds a `addPeriodsBonds` transaction to set the periods and bonds
* @param senderAddress the address of the sender
* @param periods an array of periods
* @param bonds an array of bond values
*/
setPeriodsBonds(
addPeriodsBonds(
senderAddress: IAddress,
periods: number[],
bonds: BigNumber.Value[]
Expand All @@ -826,7 +826,7 @@ export class BondContract extends Contract {
const tx = new Transaction({
value: 0,
data: new ContractCallPayloadBuilder()
.setFunction('setPeriodsBonds')
.setFunction('addPeriodsBonds')
.setArgs(combinedArray)
.build(),
receiver: this.contract.getAddress(),
Expand Down
2 changes: 1 addition & 1 deletion tests/nftminter.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ describe('Nft minter test', () => {
}
);
expect(mintTx).toBeInstanceOf(Transaction);
}, 40000);
}, 200000);

test('#mint nft using tax for minting', async () => {
const factoryGeneratedContract = new Address(
Expand Down

0 comments on commit b0c1d0a

Please sign in to comment.