how to use wifi p2p application on Android emulator

i am developing file sharing app and uses wifi p2p and wanted to test on android emmulator. but unable to do it. what i have to do to run p2p application on emmulator.
but the in this https://youtu.be/LVE2HbLt5jA vedio this guy uses it how?