I have a 15" MBP here and it runs for a bit then shuts down. I'm starting to think the cpu may be getting bad. Is there a way to test the CPU or the HD? I believe it's a mid 2012
If a Mac starts to overheat, it will shut down on its own. Check the fans and clean the vents before doing anything else. Beside the CPU is integrated into the logic board.