Let $x\sim N(\mu,\sigma^2)$ and $\mu\sim N(\xi, \tau^2)$.
To test whether $\mu<0$ or $\mu>0$, in Bayesian inference it's usual to take the perspective of hypothesis testing as model selection. In that perspective,
$M_1:\mu<0$ and $M_2:\mu>0$ .
There are at least two ways to compute $P(M_{True}=M_1|x)$. The easy one seems to use the fact that $P(M_{True}=M_1|x)=P(\mu<0|x)=\Phi(-\xi(x)/w)$, since it's known that $\mu|x\sim N(\xi(x),w^2)$ .
(to save space-time I won't write $\xi(x)$ or $w$ formula)
The second way to calculate the $P(M_{True}=M_1|x)=\frac{\int l_k(\theta)\pi_k(\theta) d\theta \ \ P(M=k)}{\sum_j\int l_j(\theta)\pi_j(\theta) d\theta \ P(M=j)}$.
I'm trying to do by the second way. However, I get $P(M_{True}=M_1|x)=1-\Phi(-\xi(x)/w)=\Phi(\xi(x)/w)$
This is based on the book Bayesian Essentials, page 40.
Any help would be appreciated.
Edit: for the second way, we define $$\pi_1(\mu)=\frac{\exp\{-(\mu-\xi)^2/(2\tau^2\}}{(2\pi \tau^2)^{1/2}\Phi(-\xi/\tau)}\mathbb{I}_{\mu<0}$$ $$\pi_2(\mu)=\frac{\exp\{-(\mu-\xi)^2/(2\tau^2\}}{(2\pi \tau^2)^{1/2}\Phi(\xi/\tau)}\mathbb{I}_{\mu>0}$$