Newer diesel engines use a turbo or baffle. Most commonly a turbo to create effective braking. This is operationally superior to jake-brakes in that the mechanism is tied into the ECM and transmission allowing for things like cruise control to function as expected. Jake-brakes on the other hand require a bit of technique by the driver to use correctly and avoid jack-knifing the vehicle with its trailer, especially on ice. Some modern pickups can even be put into "towing mode" to make better use of the add-on braking mechanism and allow cruise control to work downhill.
I suppose this the right time for an important PSA. If anyone tows something heavy in an older diesel pickup be aware the only braking you have is what your brake pedal provides. Glaze those brakes and you are going on an exciting adventure.
You can test the petrol-car-vacuum braking theory if you have an older manual petrol car with a cable from the accelerator to the butterfly valve of the throttle. While driving at 50kph, put into neutral, turn off the ignition, engage a lower gear, release clutch. Test pressing and releasing the accelerator pedal while using engine braking and feel for a difference.
SAFETY: 1. Don’t turn off the ignition all the way and lock the steering (although I admit that is very exciting to have steering locked into one direction, I don’t recommend trying it). 2. Be mentally prepared to lose power steering and power brakes. 3. Only on wide straight roads with no other traffic and safe ways to stop. 4. Probably other warnings specific to your vehicle, and situation. 5. I recommend against trying it on an automatic trans.
If your diesel has turbo vanes controlling the braking, you could probably test it out the same way (presuming electronics are disabled when ignition is off).
Another way to test things is to remove relevant fuses.
Disclaimer: there are lots of ways to screw up even being careful - I do not recommend learning by failure in deadly situations.
I suppose this the right time for an important PSA. If anyone tows something heavy in an older diesel pickup be aware the only braking you have is what your brake pedal provides. Glaze those brakes and you are going on an exciting adventure.