Let $X$ be a Topological Space. A discrete-valued map is a map $f:X\rightarrow D$ where $D$ is a discrete space. Define an equivalence relation on $X$ such that $x\simeq y$ if and only if $f(x)=f(y)$ for every discrete-valued map. Prove that every equivalence class (called quasi-component) is closed.
I am not sure about how to proceed to the proof. I though that, on the equivalence class, every map is constat so if I call $C$ the quasi-component, $C$ is a connected subspace of $X$. But I don't know how to proceed to prove that $C$ is closed. Maybe every quasi component is a connected component? Can someone help me? Thanks before!