For testing purposes, we'll use TEST collateral with the contracts deployed on Polygon. If you're testing on a live network, this step isn't necessary.
Minting TEST Tokens
First define the Collateral Token contract as a Web3 Instance:
const collateralABI = require('./abi/FakeStableCoinABI');
const collateralContract = new web3.eth.Contract(collateralABI, config.COLLATERAL_ADDRESS);
Where config.COLLATERAL_ADDRESS is the address for the TEST token defined in aconfig.js file.
You can mint TEST tokens by creating a function like below