Test Utils

Prerequisites: Java 8, Chrome/FF

The Test application

Often examples are useful in showing behaviour. Accordingly, Rubris ships with a small test application that hooks in all of the available functionality and variations of each one.

The HTML/JS for the app is stored under

rubris-io/src/main/resources/rubris/files/rubris-test

The server main class is:

rubris-io/src/test/java/com/rubris/launcher/ServerLauncher.java

Running the application (in eclipse):

  1. Clone project
  2. Import as existing maven directory
  3. To test create a new Run Configuration * Project: rubris-io * Main class: com.rubris.launcher.ServerLauncher * Arguments: 8091 login false
  4. Navigate your browser to: http://127.0.0.1:8091/rubris-test/test.html

Other IDEs may require set up of resources differently if they do not read the POM in the same way as eclipse. The above arguments set the 1. port number 2. the path root for the service calls 3. turns off the Okta connection checking

Note: To use the native options you must be running Linux Kernel 3.9 or greater.

APACHE BENCH Test

To run a load test:

  1. Download ApacheBench
  2. run against static resource on test page as above

    $ ab -n 5000000 -c 1000 -k -vv http://127.0.0.1:8091/favicon.ico

Autobahn WS tests

 1. Install autobahn
 2. Run `com.rubris.launcher.AutobahnServerLauncher`


 see src/autobahn for config script and results