" /> Genesys - Voice - How to automate testing programmatically using Genesys APIs? - Genesys CTI User Forum

Author Topic: Genesys - Voice - How to automate testing programmatically using Genesys APIs?  (Read 3353 times)

Offline bh4r4th

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Advertisement
We do a lot of manual testing for our applications.

Steps that we follow:
1. Login to Softphone
2. Open connection to TServer/SipServer in Genesys test phone
3. Register DN
4. Do agent login
5. Make agent ready
6. Make a call to agent by dialling TFN
7. Answer the call
8. Do steps 1-7 for other agents
9. Do consult/transfer/conference using Genesys test phone
10. Monitor the events using PSDK & record calls through media gateway

My question is if we can automate above steps 1-9 using any Genesys APIs/SDKs through programming instead of via Genesys test phone/Softphone?

Could you advise or guide me as how I can automate my requirement?
« Last Edit: June 17, 2017, 01:11:38 PM by bh4r4th »

Offline genesysguru

  • Sr. Member
  • ****
  • Posts: 293
  • Karma: 12
    • Genesys Guru Blog
Hi,

In a SIP environment you need some sort of SIP endpoint such as PJSUA which is an open source command line SIP user agent (softphone) . For example, the command below will automatically answer all incoming calls with 200/OK, playback the WAV file to incoming calls, and loopback the calls media to itself (remote will hear the file mixed with their own voice):
NOTE: PJSUA player port supports for reading WAV file with uncompressed 16 bit PCM format or compressed G.711 A-law/U-law format.

pjsua --config-file test.cfg --play-file c:\pjsip\1001.wav --auto-answer 200 --auto-play --auto-loop --max-calls 10

In terms of CTI control you can used the platform SDK to write some code to login and make test agents associated with PJSUA SIP EPs (DNs) ready etc. There are plenty of code samples available.

Regards
Craig

Offline bh4r4th

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Thanks Craig. What if I use TLib functions to do steps 1-9? It should work right? But, one more doubt is how do I dial to a TFN programmatically to fully automate it?
« Last Edit: June 17, 2017, 01:12:48 PM by bh4r4th »

Offline cavagnaro

  • Administrator
  • Hero Member
  • *****
  • Posts: 7641
  • Karma: 56330
Please don't double post

Enviado de meu E6633 usando Tapatalk


Offline cavagnaro

  • Administrator
  • Hero Member
  • *****
  • Posts: 7641
  • Karma: 56330
If you use API you are adding another point of failure. You would need tests to validate that your tests tools work fine ;)

Enviado de meu E6633 usando Tapatalk


Offline bh4r4th

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
@cavagnaro Pardon me for the duplicate post. "If you use API you are adding another point of failure. You would need tests to validate that your tests tools work fine" - Could you mention in detail?

- My idea is to automate steps 1-9 through Genesys PSDK/TLib functions. To dial TFN, I plan to use Avaya communicator, along with any UI automation framework.
« Last Edit: June 17, 2017, 01:13:28 PM by bh4r4th »

Offline cavagnaro

  • Administrator
  • Hero Member
  • *****
  • Posts: 7641
  • Karma: 56330
You could use TestSoftphone from Genesys. Ask for it at support site.
My comment goes that I'm you are trying to test something you developed to automate the inputs. If you develop something to use the Genesys SDK then you would have what you are asking for but with the risk of a scenario not controlled like an error on the place for example.
You would have to develop something to control agent login then something to dial in like what Craig mentioned.

Enviado de meu E6633 usando Tapatalk

Offline bh4r4th

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Thanks for the replies. I plan to use PSDK APIs to manage connecting to Genesys servers, agent login, answering calls. To dialling, yet to decide.

Offline cavagnaro

  • Administrator
  • Hero Member
  • *****
  • Posts: 7641
  • Karma: 56330
Guess Genesys Test Softphone could help you for that login task

Enviado de meu E6633 usando Tapatalk


Offline jamesmurphyau

  • Full Member
  • ***
  • Posts: 123
  • Karma: 2
I've written a power shell script that let me login and make constant calls between two WDE clients on the same machine..

I used UIAutomation to login and make the calls.. then WDE and SIP endpoint handled everything in terms of audio.. but I was not testing the audio so I didn't need to play or listen for a particular thing - only logi. And do some basic functions then end the call all via WDE

Offline jamesmurphyau

  • Full Member
  • ***
  • Posts: 123
  • Karma: 2
I can share the project on GitHub if anyone is interested

Offline Atechie

  • Newbie
  • *
  • Posts: 8
  • Karma: 0
Hi

Can you please put it on Github and share a bit more how it works.