Ok really simple, but I must be missing something in the theory.
If my $$H_0:p=.5$$ and $$H_1:p>.5$$
What happens if the sample data implies that $p<.5?$ Clearly my $H_0$ would be rejected, but then I would have to accept my $H_1$, which would contradict my known value of $p.$
So what am I missing?
If you have only two hypotheses as above, you are sure that no other cases is possible. Sample data cannot implies smth about $p$ with complete confidence. Even if $\overline X<0.001$, this supports the null hypothesis.
But in practice, if you get sample values as in this example, this will be a reason to reconsider the grounds on which these two hypotheses were put forward.