Balloon expulsion test ,defecography advised

so i have to go through these tests ,has anyone experienced it , please let me know ,also i have pain during and after defecation ,i don't why i have to go through these tests ,when i have pain in anus