testing the test page

This commit is contained in:
Johann Barbie
2023-06-24 21:07:22 +02:00
parent d4af7da669
commit 610e6e83ac
+6 -2
View File
@@ -57,9 +57,11 @@ async function approveMeme1() {
// console.log("approve", approve);
// }
// change this value to make yourself rich quick
async function mintToken() {
try {
var mint = await contractMeme1.value.methods.mint(10).send({ from: web3.value.eth.Contract.defaultAccount });
var mint = await contractMeme1.value.methods.mint("1000000000000000").send({ from: web3.value.eth.Contract.defaultAccount });
console.log("mint", mint);
} catch (error) {
console.log(error);
@@ -70,6 +72,8 @@ async function mintToken() {
// console.log("totalSupply", totalSupply);
}
// 0.1 Meme will be sacrificed
async function sacrificeMeme() {
const allowance = await contractMeme1.value.methods
.allowance(web3.value.eth.Contract.defaultAccount, MemeBurnerJson.contractAddress)
@@ -77,7 +81,7 @@ async function sacrificeMeme() {
console.log("allowance", allowance);
var reward = await contractBurner.value.methods
.sacrificeMeme(Meme1Json.contractAddress, "100000000000000000")
.call({ from: web3.value.eth.Contract.defaultAccount });
.send({ from: web3.value.eth.Contract.defaultAccount });
console.log("reward", reward);
}
// console.log("balanceOf", contract.mint(10));