Neither they know if they will be the ones finding the current block.
Hi TryNinja, thanks for your reply!
As I explained in the first post, miners just have to not relay those spammy transactions into the bitcoin network until they mine the block, so that they don't get included in the blockchain by other miner.
When they finally mine a block and broadcast it, that's the first time the network gets to know about those spammy txs, and the miner gets back all the fees that they spent.