Skip to content

eggcloud/webrtc-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 

Repository files navigation

webrtc-test

Framework for functional and Load Testing of WebRTC

selenium-webload.png

Install prerequisites

CentOS 7

Ubuntu 16.04

  • Install chrome:
$ wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
$ sudo sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list'
$ sudo apt-get update
$ sudo apt-get install google-chrome-stable

Initiate load tests

1. Start monitoring

  • on CentOS
# psmon.sh

import sys
import pmm

import matplotlib
matplotlib.use('Agg')

if __name__ == '__main__':
    sys.exit(pmm.main())

$ psmon.sh <PID> --log <FILENAME> --plot <FILENAME> --interval <SECS> --duration <SECS>

2. Run webtest

  • on Ubuntu
# webtest.py

from selenium import webdriver

options = webdriver.ChromeOptions()
options.add_argument('headless')
options.add_argument('window-size=1280x720')
options.add_argument("disable-gpu")
options.add_argument('no-sandbox')
options.add_argument("use-fake-device-for-media-stream");
options.add_argument("use-fake-ui-for-media-stream");

driver = webdriver.Chrome(<CHROMEDRIVER_PATH>, chrome_options=options)
driver.get(<URL>)
driver.implicitly_wait(30)
driver.find_element_by_id("start").click()

#driver.quit()

$ py.test -n <numprocesses> webtest.py

3. End monitoring

  • Terminate process with <CTRL+C> on CentOS
  • Log files generation and test results recording

Analyze the results

A quad core CPU with 8GB RAM, 640x480 1Mbits/s pslog1.txt pslog1.png

About

Framework for functional and Load Testing of WebRTC

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published