Short answer. A bad eBike controller usually shows as intermittent power, error codes, motor not responding to throttle, or complete no power with a charged battery. Controllers fail from heat, water, and voltage spikes from bad chargers.
Step by step
Rule out the battery and display. A load tested good battery and a known good display point the finger at the controller.
Look for error codes. E03 on Rad, 021 or 030 on Bafang all indicate controller communication issues.
Feel the controller housing. A hot controller during moderate riding suggests internal shorts. Check the housing after a 10 minute ride.
Swap test. The definitive test is swapping in a known good controller. Mobile mechanics carry common controllers on the van for most major brands.