Actually this is not quite right: you need to exclude $k = 0$.
If $(k,x) \in \mathbb Z$ and $k \
e 0$, then $f(t) = \exp\left(2\pi i (k, t)\right)$ is invariant under $L_{\pi(x)}$ and is not a.e. constant.
Conversely, if $f \in L^1(\mathbb T^n)$ is invariant under $T_{\pi(x)}$, look at the Fourier transform of $f$: $\widehat{f}(k) = \int_{\mathbb T^m} \exp(-2\pi i (k,t)) f(t)\; dt$ (where $dt$ is normalized $m$-dimensional Lebesgue measure on $\mathbb T^m$). Since $\widehat{L_{\pi(x)} f}(k) = \exp(2\pi i (k,x)) \widehat{f}(k)$, we must have $(k,x) \in \mathbb Z$ for any $k$ such that $\widehat{f}(k) \
e 0$. If there are no such $k$ except $0$, then (by the fact that Fourier transform is one-to-one on $L^1$) $f$ is a.e. constant.