Let $G$ be a compact group (maybe non-Lie group). Let $B_{G}$ denote the classifying space of $G$. If $G$ contains a circle group $\mathbb{S}^{1}$, then I think that $H^{\ast }( B_{G};\mathbb{Q} )$ is not trivial, where $H^{\ast }$ is the cohomology algebra. I don't know how exactly to prove this.
I just know this: If $G$ is a torus and $H$ is a subtorus of $G$, then $H^{\ast }( B_{G};\mathbb{Q} ) \longrightarrow H^{\ast }( B_{H};\mathbb{Q} )$ is surjective.