My phone's vibration not working intermittently.
Go to calculator and type in .12345+=
Do single test and then perform vibration tests.
If one fails, go to service centre. But it sounds like you need to go service centre anyway.
Possibly a hardware issue, you can try the SMMI test steps shared by ronald above. Also, try factory reset once. Nothing works,
Kindly visit the nearest service center:
Due to the lockdown, service centers may not be functional. Kindly call the service center before you visit one.