An effective criterion to prevent injection test numerical simulation from spurious oscillations