For future readers: the $\beta_1$ in @MichaelChirico's post is \beta_wald (the average treatment effect, in usual use), and the covariance formula follows from $E[Y|X] = \beta_0 + \beta_1 X$ without loss of generality (since X is binary). (Apologies for the extra answer; I have insufficient reputation to comment)