I am trying to write a test for one of my smart contract functions but I'm finding it difficult to change the value of msg.sender to 0x0.
I know that msg.sender's value is gonna be the address that has called or initiated the function or created the transaction but for this test I need to set it to 0x0.
Here is the function inside my contract:
function claimToken(address nativeTokenAddress, uint256 amount) public {
require( amount > 0, 'Trying to claim 0 tokens.');
require(msg.sender != address(0x0)); <---- I need to test this
//some extra function is here
emit Claimed(msg.sender, amount, wrappedTokenAddress);
}
Here is the test I've written:
it("Should revert claimToken if msg.sender is 0x0.", async function() {
await bridgeBase.claimToken(rinkebyToken.address, 50).call({from:'0x0000000000000000000000000000000000000000'});
})
How can I test this require section of the claimToken function?