I've never had an issue with the relays, so I'm not sure. But if it is clicking then I'm sure it's working.
One way to check if relays are working. Start car from cold, touch relays after 10-15 mins of driving or ideling, if they are warm then they are functioning properly, if they are cold, you got a naffd relay
check the fuel pump relay and ecu relay, both common to go and will keep cutting out engine.
Also another thing to note, when your car cuts out, does the oil light flash?