ERC721PausableMock.sol 988 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. // SPDX-License-Identifier: MIT
  2. pragma solidity ^0.8.0;
  3. import "../token/ERC721/extensions/ERC721Pausable.sol";
  4. /**
  5. * @title ERC721PausableMock
  6. * This mock just provides a public mint, burn and exists functions for testing purposes
  7. */
  8. contract ERC721PausableMock is ERC721Pausable {
  9. constructor(string memory name, string memory symbol) ERC721(name, symbol) {}
  10. function pause() external {
  11. _pause();
  12. }
  13. function unpause() external {
  14. _unpause();
  15. }
  16. function exists(uint256 tokenId) public view returns (bool) {
  17. return _exists(tokenId);
  18. }
  19. function mint(address to, uint256 tokenId) public {
  20. _mint(to, tokenId);
  21. }
  22. function safeMint(address to, uint256 tokenId) public {
  23. _safeMint(to, tokenId);
  24. }
  25. function safeMint(address to, uint256 tokenId, bytes memory _data) public {
  26. _safeMint(to, tokenId, _data);
  27. }
  28. function burn(uint256 tokenId) public {
  29. _burn(tokenId);
  30. }
  31. }