mirror of
https://github.com/Instadapp/aave-protocol-v2.git
synced 2024-07-29 21:47:30 +00:00
Fixed borrow negatives
This commit is contained in:
parent
78023ae5c3
commit
8af0e9fd11
|
@ -3,7 +3,7 @@
|
|||
"description": "Test cases for the deposit function.",
|
||||
"stories": [
|
||||
{
|
||||
"description": "User 0 deposits 1000 DAI, user 1 deposits 1 ETH as collateral and tries to borrow 100 DAI with rate mode NONE (revert expected)",
|
||||
"description": "User 0 deposits 1000 DAI, user 1 deposits 1 WETH as collateral and tries to borrow 100 DAI with rate mode NONE (revert expected)",
|
||||
"actions": [
|
||||
{
|
||||
"name": "mint",
|
||||
|
@ -31,14 +31,30 @@
|
|||
},
|
||||
"expected": "success"
|
||||
},
|
||||
{
|
||||
"name": "mint",
|
||||
"args": {
|
||||
"reserve": "WETH",
|
||||
"amount": "1",
|
||||
"user": "1"
|
||||
},
|
||||
"expected": "success"
|
||||
},
|
||||
{
|
||||
"name": "approve",
|
||||
"args": {
|
||||
"reserve": "WETH",
|
||||
"user": "1"
|
||||
},
|
||||
"expected": "success"
|
||||
},
|
||||
{
|
||||
"name": "deposit",
|
||||
"args": {
|
||||
"reserve": "WETH",
|
||||
|
||||
"amount": "1",
|
||||
"user": "1",
|
||||
"sendValue": "1"
|
||||
"user": "1"
|
||||
},
|
||||
"expected": "success"
|
||||
},
|
||||
|
@ -56,7 +72,7 @@
|
|||
]
|
||||
},
|
||||
{
|
||||
"description": "User 0 deposits 1000 DAI, user 1 deposits 1 ETH as collateral and tries to borrow 100 DAI with an invalid rate mode (revert expected)",
|
||||
"description": "User 0 deposits 1000 DAI, user 1 deposits 1 WETH as collateral and tries to borrow 100 DAI with an invalid rate mode (revert expected)",
|
||||
"actions": [
|
||||
{
|
||||
"name": "mint",
|
||||
|
@ -84,6 +100,23 @@
|
|||
},
|
||||
"expected": "success"
|
||||
},
|
||||
{
|
||||
"name": "mint",
|
||||
"args": {
|
||||
"reserve": "WETH",
|
||||
"amount": "1",
|
||||
"user": "1"
|
||||
},
|
||||
"expected": "success"
|
||||
},
|
||||
{
|
||||
"name": "approve",
|
||||
"args": {
|
||||
"reserve": "WETH",
|
||||
"user": "1"
|
||||
},
|
||||
"expected": "success"
|
||||
},
|
||||
{
|
||||
"name": "deposit",
|
||||
"args": {
|
||||
|
|
|
@ -12,7 +12,7 @@ BigNumber.config({DECIMAL_PLACES: 0, ROUNDING_MODE: BigNumber.ROUND_DOWN});
|
|||
|
||||
const scenarioFolder = './test/helpers/scenarios/';
|
||||
|
||||
const selectedScenarios: string[] = ['redeem-negatives.json'];
|
||||
const selectedScenarios: string[] = ['borrow-negatives.json'];
|
||||
|
||||
fs.readdirSync(scenarioFolder).forEach((file) => {
|
||||
if (selectedScenarios.length > 0 && !selectedScenarios.includes(file)) return;
|
||||
|
|
Loading…
Reference in New Issue
Block a user