-
Notifications
You must be signed in to change notification settings - Fork 4
Testing and call simulation
=== The following is a DRAFT version ===
You'll find scripts for:
- SIP call simulation (via sippy_cup)
- Call event simulation (via Amqp-messaging)
- and a Selenium suite (via VNC/Firefox)
All of them wipe/alter the DB contents, so they will refuse to run in production environments.
To run these specs, log into the VM via ssh (vagrant ssh) and go to the Voice-Specs directory /opt/voice-specs (alias: vs)
To visualize the system state during the tests:
> svsa (shows the state of the Voice services)
> ot (shows a tail of all ruby based service logs)
> t (opens htop and shows the active processes)
We recommend using the latest Chrome version, as it's the fastest platform known to us. To log in with multiple users (admin/agents), create several profiles and open a separate browser window for each of them.
This creates a number of simultaneous SIP calls with sipp. They are coming from the admin extension (default 999) and dial into the internal IVR menu (number 00). To be able to see the effect, log in as admin with the browser-interface (https://voice01.wimdu.com if you followed the VM setup). If you register a SIP phone as one of the agents and also log in via https, you'll get some of the incoming calls.
> vs
> cp config/load.yml.example config/load.yml
> script/create-fake-agents
> script/do-sip-calls
This simulation emits Amqp messages as if they were coming from real calls — but without touching the SIP server domain. So most aspects of the event processing and display are covered. Login as admin to the web front-end to see the active calls. If you also login with one or more agents (one browser session per user) you'll see the default call cycle as described in this intro video.
> vs
> script/create-fake-agents
> script/replay-events 200
This is a suite of rspec/capybara tests that fire up some browsers in the VNC screen and target the whole development environment. By launching the script you will reset all database contents. To actually see the browser actions, connect with a VNC client to the Vagrant VM (with the password that you used for setup).
> vs
> script/browser-suite