From b62b926ada0101a267d028b595ae5cdd4223c618 Mon Sep 17 00:00:00 2001 From: lza_menace Date: Mon, 9 Jan 2023 01:55:07 -0800 Subject: [PATCH] change name --- src/Mailbomb.sol | 2 +- src/Main.sol | 2 +- src/Unaboomer.sol | 2 +- test/Unaboomer.t.sol | 28 ++++++++++++++++++++++++++++ 4 files changed, 31 insertions(+), 3 deletions(-) diff --git a/src/Mailbomb.sol b/src/Mailbomb.sol index b0d9565..2f3c8ce 100644 --- a/src/Mailbomb.sol +++ b/src/Mailbomb.sol @@ -7,7 +7,7 @@ import {Main} from "./Main.sol"; /** @title Mailbomb -@author 0xgrimey.eth +@author lzamenace.eth @notice This contract contains ERC-1155 Mailbomb tokens (BOMB) which are used as utility tokens for the Unaboomer NFT project and chain based game. Mailbombs can be delivered to other players to "kill" tokens they hold, which diff --git a/src/Main.sol b/src/Main.sol index 21d73a8..cfa621e 100644 --- a/src/Main.sol +++ b/src/Main.sol @@ -56,7 +56,7 @@ import {Mailbomb} from "./Mailbomb.sol"; /** @title UnaboomerNFT -@author 0xgrimey.eth +@author lzamenace.eth @notice This is the main contract interface for the Unaboomer NFT project drop and chain based game. It contains the logic between an ERC-721 contract containing Unaboomer tokens (pixelated Unabomber inspired profile pictures) and an ERC-1155 contract containing Mailbomb tokens (utility tokens). diff --git a/src/Unaboomer.sol b/src/Unaboomer.sol index ca76164..bdb31b5 100644 --- a/src/Unaboomer.sol +++ b/src/Unaboomer.sol @@ -8,7 +8,7 @@ import {Main} from "./Main.sol"; /** @title Unaboomer -@author 0xgrimey.eth +@author lzamenace.eth @notice This contract contains ERC-721 Unaboomer tokens (BOOMR) which are the profile picture and membership tokens for the Unaboomer NFT project and chain based game. Each Unaboomer is a unique, dynamically generated pixel avatar in the likeness diff --git a/test/Unaboomer.t.sol b/test/Unaboomer.t.sol index ba4790e..5153649 100644 --- a/test/Unaboomer.t.sol +++ b/test/Unaboomer.t.sol @@ -85,6 +85,34 @@ contract UnaboomerTest is Test { assertEq(main.bombsExploded(), 5); } + // ensure sending bombs doesn't bork + function testSendBombErrors() public { + hoax(address(1)); + main.radicalizeBoomers{value: unaboomerPrice * 35}(35); + hoax(address(2)); + main.radicalizeBoomers{value: unaboomerPrice * 35}(35); + hoax(address(3)); + main.radicalizeBoomers{value: unaboomerPrice * 35}(35); + startHoax(address(4)); + main.assembleBombs{value: bombPrice * 200}(200); + vm.warp(2); + main.sendBombs(1); + vm.warp(300); + main.sendBombs(1); + vm.warp(400); + main.sendBombs(1); + vm.warp(500); + main.sendBombs(1); + vm.warp(6000); + main.sendBombs(1); + vm.warp(7000); + main.sendBombs(1); + vm.warp(8000); + main.sendBombs(1); + vm.warp(9000); + main.sendBombs(1); + } + // ensure wallet limits enforced function testWalletMintLimit() public { uint256 max = main.unaboomerMaxMintPerWallet();