In the case of surfaces, the necessary and sufficient condition is the absence of asymptotic values.
A curve in $\gamma:[0,1)\to X$ is called an asymptotic curve if the limit $\gamma(t)$
as $t\to\infty$ is $\infty$ (the infinite point of one point compactification of $X$),
but $f(\gamma(t))$ has a limit in $Y$ as $t\to 1$. This limit is called an asymptotic value.
A covering is a local homeomorphism that has no asymptotic values.
The only references for this that I know are for surfaces, but this should not be hard to prove
in general under appropriate conditions. Probably $X$ and $Y$ have to be locally connected,
in addition to what you said about them.