Why do we use $P_0$ instead of $\hat{p}$ for sample proportion Hypothesis Testing? It seems that most people favor using $$t_{stat} = \frac{\hat{p}-p_0}{\sqrt{p_0(1-p_0)/n}}$$ instead of $$t_{stat} = \frac{\hat{p}-p_0}{\sqrt{\hat{p}(1-\hat{p})/n}}$$
when doing Hypothesis Testing with sample proportions (at least so were we told in class).
This doesn't make sense to me, since we use $s$ for sample means, and especially in a case for example where we would be testing for whether or not a coin is biased.
How does it make sense to use $p_0$ if we're already suspecting that the coin might be biased? Why not use $\hat{p}$ the way we use $s$ for sample means? 
 A: People use $p_0$ instead of $\hat{p}$ because in hypothesis testing we want to know how likely it is to observe the current sample assuming that the null hypothesis is true. If the null hypothesis is true, we know the standard deviation in case of a Binomial experiment, and we should use it!
On the other hand, I imagine the $s$ you are referring comes from doing doing hypothesis tests on normal distributions (or some unknown distribution and applying the CLT) where we want to test for the mean ($\mu$) but we don't know the standard deviation ($\sigma$). Hence, we have no $\sigma$ to plug in, and have no choice but to use an estimate for the standard deviation, $s$.
Indeed, if $\sigma$ is known, one should use it over $s$ just like here we use $p_0$ instead of $\hat{p}$.
A: In the second formula, you are using the normal approximation which can be used when the number of trials is large. For normally distributed variables, the mean and variance are independent of each other, so you have to use the estimated variance below since you do not know it. This is also why the normal distribution has two parameters.
However, with a binomially distributed variable, the mean and variance are not independent. This is why it has only one parameter. Under the null that $p=p_0$, this pins down the variance as $p_0 \cdot (1-p_0)$, so you can use that instead.
A: The basic question is pretty much covered already, so I won't belabour that beyond a brief mention -- but I have some additional comments. Briefly, then, we see that significance is based on looking at the distribution of test statistics when the null is true. So in this situation you can use the standard error under the null (i.e. you can use $p_0$ in the standard error), and then you can directly use the normal approximation to the (scaled) binomial numerator to derive an asymptotically normal test. This should be fully efficient as $n\to\infty$.
On the other hand, it would also be sensible (and valid) to replace the standard error computed under the null by some asymptotically efficient estimate, such as the MLE -- as long as we can (i) compute an approximate distribution for this statistic under the null, and (ii) as long as the properties of the resulting test are reasonable.
One (small) advantage is that it would then make the hypothesis test consistent with the large-sample confidence interval (the decision rule in the hypothesis test at level $\alpha$ would correspond to whether or not the null value was in a confidence interval of coverage $1-\alpha$.
The issue then is one of how to deal with this test statistic. It should be asymptotically normal via Slutsky's theorem and the CLT. In small samples the exact distribution under the null can be obtained from the binomial itself.
Using such a statistic is recommended in some texts. Often those texts recommend using a t-approximation for this statistic, and examining the behaviour in small samples this seems as if it may perform quite well.
