Since you say the wiring has been tampered with, I would start by getting the proper manual and wiring diagrams from JD, and then tracing out each wire to see if it is in the correct place. If the wire diagram is electronic then have a couple large copies printed you can work from. If it is in the manual in paper, get it scanned and have some large copies made. Then check off each wire on the copy as you verify it. Once that is done if the behavior is the same, just remember that a diesel engine needs fuel and air to run. The compression and heat should keep it running as most diesels run wide open all the time and vary the fuel injected to vary power. A pressure gauge should tell you if the needed fuel pressure is there, and I would guess the injectors are electronic so a noid light should tell you if the injectors are getting a signal. If this is some mechanical injector monstrosity that runs with cams and gears, then all bets are off. It could be as simple as a floating piece of rag in the fuel tank, or a bad fuel pump - meaning it works fine until it heats up.
Because of the power in numbers, what he said.
Buy the JD technical manual for your mower
It will have full details of how to test the mower then how to fix it including where all of the parts are hidden
Usually the JD tech manual has a full engine manual for the engine fitted that is better than the OEM engine makers manual
Electronic fuel injection engines can be shut down by the lift pump shutting off, the injectors shutting off , the pressure pump shutting off ,the fuel line solenoid shutting off .
A little tool we use on the farm gear is a LED instrument light with a long pigtail and some aligator clips on the end
We hook this up to various components and see when it turns off or lights up as the case may be
An electric pump might work fine till it gets hot then fail so it has to be tested both hot & cold .
The fuel tank vent could be blocked so it is a simple vacuum lock
And as already mentioned, floating crud in the tank blocking off the outlet.
But buy the file ( the digital down loads are a lot cheaper than the hard print ) , pour your self a good strong coffee then sit down and read it cover to cover
When finished you will know more than most service techs.
JD usually include a "theory of operation" at the beginning of each section so you can understand what is happening and why which is a big plus when you ned to work out what is not happening.