Scotty agrees to be a test subject for McCoy's gas grenade on one condition: that he's "wide awake" for the gunfight at five o'clock. McCoy says he guarantees it. At the time this exchange occurs, it is about ten minutes before five. If McCoy really believes the gas is going to be effective, how can he possibly make such a guarantee?
Because as soon as Scotty passes out, they would remove the canister and give him fresh air, reviving him. In battle, they would open the grenade and leave it there, so their opponents would continue getting slowly poisoned until either death or until Kirk and crew have time to figure out another plan.
And besides, dear Scotty had been drinking shots of whiskey all day, and he seemed awfully chipper about the prospect of near-certain death at 5 o'clock if he didn't believe it would work.