There’s a tool for that! In most circumstances, a plug-in receptacle tester can tell if you if the receptacle is wired and grounded correctly; you can find them at most home improvement stores for around $10.