Skip to content
This repository has been archived by the owner on Jun 9, 2022. It is now read-only.

[Archived] Smoke tests and sanity checks for all production IATI websites and web tools.

License

Notifications You must be signed in to change notification settings

IATI/IATI-Website-Tests-archived

Repository files navigation

[Archived] IATI Website Tests

https://travis-ci.org/IATI/IATI-Website-Tests.svg?branch=master Requirements Status

Introduction

This repository contains smoke tests and sanity checks for all live IATI websites and web tools.

The output of tests can be seen at: https://travis-ci.org/IATI/IATI-Website-Tests

Technology Overview

Tests are written using pytest using Python 3.7.

Most tests are designed to obtain HTML and associated content from IATI websites, using the requests library. This retries failed requests several times should a failure occur, so as to reduce flakiness. Additional tests on the status of backups are made using the paramiko module, which checks the status of expected backup files via an SSH connection.

These tests are run daily (at around 2pm) using Travis cron jobs. They are also run every 15 minutes throughout the day by use of a Travis API call from an IATI-managed server.

For a more detailed of the test architecture, view the README under tests.

The current status of the tests can be seen on the Travis site.

Installation

# Create a virtual environment using python 3
python3 -m venv pyenv

# Activate the virtual environment
source pyenv/bin/activate

# Install requirements
pip install -r requirements.txt

# Login credentials for the IATI backup server are stored as environment variables.
# Add these lines to the end of your virtualenv set-up script - i.e. pyenv/bin/activate
export backup_server_hostname='[YOUR_HOSTNAME]'
export backup_server_username='[YOUR_USERNAME]'
export backup_server_password='[YOUR_PASSWORD]'

# Run the tests
py.test tests/

About

[Archived] Smoke tests and sanity checks for all production IATI websites and web tools.

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages