Let $v \in \text{Hom}(M,M')$ Then if the induced hom $\bar{v} : \text{Hom}(M',N) \to \text{Hom}(M,N)$ given by $f \mapsto f \circ v$ is injective for all $N$, then $v$ is surjective.
Attempted proof 1. A function is injective iff it has a a left inverse, and surjective iff it has a right inverse function. Let $N = M'$. What we want is $v \circ g = \text{id}_{M'}$ for some $g \in \text{Hom}(M',M)$. What we have is that for all modules $N$, $\bar{v} : f \mapsto f \circ v$ is injective, ie. there exists $\bar{g}$ such that $\bar{g} \circ \bar{v} = \text{id}_{M'}$. And.. I'm lost.
Attempted proof 2. Let $v \in \text{Hom}(M,M')$, then by hypothesis $\bar{v}: \text{Hom}(M',N) \to \text{Hom}(M,N)$ is injective for all modules $N$ meaning that there is $\bar{u} : \text{Hom}(M,N) \to \text{Hom}(M',N)$ such that $\bar{u}\circ\bar{v} = \text{id}_{\text{Hom}(M',N)}$. Let $N = M$ and $\bar{u}$ be such.
Apply the property to $p:M'\rightarrow N=\operatorname{coker v}$. By definition $p\circ v=0$, so $p=0$ since $\bar v$ is injective. This means exactly $v$ is surjective.