'Mock Bluetooth device appium

I am currently testing a native mobile app using appium automation with java. Currently testing with android. In that app, I need to connect to a Bluetooth device which actually a physical device.

For example, if i click 'connect to a x device' then it will look for that physical device using device id and show that device in the Bluetooth device list within in the app. Currently I don't have that physical device to pair. So I need to mock it.

How to mock this device to show up as fake device in the list so I can select and continue to next step.

Is there any way I can do it programmatically or any inbuilt function from appium to do it.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source