Let $X$ be a connected (based) CW-complex, $X$ is called simple if $\pi_1(X)$ acts trivially on $\pi_n(X)$ for all $n\geq 1$. The Whitehead theorem states that a self-map of a simple connected CW-complex $X$ is a homotopy equivalence if and only if the induced homological homomorphism $H_n(f)\colon H_n(X)\to H_n(X)$ is an automorphism for all $n\geq 1$.
Q: Is there a CW-complex $X$ satisfying the following conditions:
$(a)$ $X$ is not simple;
$(b)$ For any self-map $f\colon X\to X$, if the induced homological homomorphism $H_n(f)$ is an automorphism for all $n\geq 1$, then $f$ is a homotopy equivalence.