I think I know where you are stuck. The linked text states
On the other hand, if our question is whether Mr. Bond is better than chance at determining whether a martini is shaken or stirred, we would use a one-tailed probability
Now, the statement "better than chance" suggests we should test with $H_0: \theta = \frac{1}{2}$, and you are right. So we could test
$$ H_0 : \theta = \frac{1}{2}, \text{ against } H_1: \theta > \frac{1}{2}$$
So why author wrote $H_0: \theta \le \frac{1}{2}$? Maybe he wanted to emphasize that we do not check for $\theta < \frac{1}{2}$ in alternative $H_1$. It may also be important to note that in this case the complex hypothesis
$$H_0 : \theta \le \frac{1}{2}, \text{ against } H_1: \theta > \frac{1}{2}$$
Has the same uniformly most powerful test as the above simple one, and the author just assumed it is known. That is, we use the same test statistic to determine p-value of the test.