Skip to content
This repository was archived by the owner on May 12, 2021. It is now read-only.

Files

Latest commit

Feb 26, 2019
e67f7b2 · Feb 26, 2019

History

History
This branch is 19 commits behind develop.

tests

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Oct 26, 2017
Feb 26, 2019
Jun 13, 2017
Jun 5, 2017
Oct 21, 2017
Feb 27, 2018
Mar 20, 2017
Mar 20, 2017
Oct 26, 2018
Jul 3, 2017
Nov 2, 2016
Oct 26, 2018
Jun 5, 2017
Jul 3, 2017
Oct 26, 2018

README.md

Testing PredictionIO

Intention of this subdirectory is to amass different types of tests other than unit-tests and also to make developers life easier giving them with means to check the application deterministically for different configurations. Moreover, it provides testing scenarios for TravisCI to be run on pull requests and commits.

Integration Tests

These tests are mostly user-functionality tests. They check logic and reliability of the system. In order to get familiar with their structure, please see README.

Docker image

After introducing some changes, a developer would like to try them against different configurations, namely to see if everything works as expected e.g. when you change the data repository for the events or meta-data. A good way to that is to use the docker image with installed and running dependencies.

To download the image run:

$ docker pull predictionio/pio-testing

To build the image use the script:

$ tests/docker-build.sh <image_name>

This is necessary to infer proper versions of dependencies e.g. Spark to be included in the image.

The most convenient way to make use of it is to execute run_docker.sh script passing it the configuration, the path to PredictionIO's repository with archived snapshot and the command to run. When no command is provided it opens a bash shell inside the docker image. Example of usage:

$ ./run_docker.sh ELASTICSEARCH HBASE LOCALFS \
    ~/projects/predictionio "echo 'All tests passed...'"

Directory structure inside the image:

  • /PredictionIO - extracted snapshot (/PredictionIO/bin is also already added to PATH)
  • /pio_host - mounted path to repository
  • /tests/pio_tests - copy of integration tests
  • /vendors - directory with installed services
  • /drivers - jars with database drivers