If you wish to test the inputs, disconnect all external devices from the inputs
and test each input by connecting it to field power (+24V in your case)
Note the touching the screw on the connector is not reliable unless the screw is tight
If the NPN limit switch outputs are not very close to ground in one state,
you still have a wiring error.