block = await ethers.provider.getBlockNumber();
            let value = 10000 - block - 1;
            //快速推进到100000区块前一个
            await ethers.provider.send("hardhat_mine", [convertNum(value)]);

            console.log(await ethers.provider.getBlockNumber());

            // 时间戳推后30天
            var timestamp = Math.round(new Date() / 1000)
            await ethers.provider.send("evm_mine", [timestamp + (3600*24*30)]);
            blocktime = (await ethers.provider.getBlock()).timestamp;  
            console.log(myDate(blocktime, 1));

错误判读

await expect(Lock.deploy(latestTime, { value: 1 })).to.be.revertedWith(
        "Unlock time should be in the future"
      );

参考 https://blog.csdn.net/fpcat/article/details/124457738