How to upgrade Mac Pro 4.1 to 5.1 and run Apple’s Hardware Tests from a USB stick

I recently decided against building my own server from ordered parts and simply bought an older Mac Pro for a good value. It was roughly 200€ more than the build-it-yourself way, but therefor it can run OS X smoothly, which saves me time where I don’t need to babysit my machine.

Nevertheless, it can not go without a bit of hacking.
read on how to upgrade to 5.1 and run Apple’s Hardware Tests from an USB Stick