Let $(X,\mathcal B,\mu)$ be a probability space and $T\colon X\rightarrow X$ be measure preserving. I need to prove that $T$ is ergodic if and only if the following property holds:
If $f\colon X\rightarrow\Bbb R$ is measurable and satisfies $f(T(x))\geqslant f(x)$ almost everywhere, then $f$ is constant almost everywhere.
We have the following result (see Ergodic Theory wiht a view towards numbers theory by Eiseidler and Ward, GTM.
One direction is quite easy: assume that for all $f$ measurable satisfying $f(Tx)\geqslant f(x)$ almost everywhere we have that $f$ is constant almost everywhere. Take $A$ such that $T^{-1}(A)=A$. With $f:=\chi_A$, we get what we want.
Conversely, assume $T$ ergodic. For each real number $R$, define $$S_R:=\{x,\sup_{n\geqslant 1}f(T^nx)\leqslant R\}.$$ Each $S_R$ is almost invariant, so $\mu(S_R)\in\{0,1\}$ for each $R$. Define $R_0:=\inf\{R>0,\mu(S_R)=1\}$. Then $f=R_0$ almost everywhere.