How do you test an electronic control unit?

How do you guys test if an ECU has gone kaput?