summaryrefslogtreecommitdiff
path: root/.travis.yml
blob: f5db00296a17dfee1e32183c55ed54322e9f2106 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
language: python

os:
  - linux

python:
  - "pypy"
  - "2.6"
  - "2.7"
  - "3.2"
  - "3.3"

matrix:
  include:
  # Also run the tests against cryptography master.
  - python: "2.6"
    env:
      CRYPTOGRAPHY_GIT_MASTER=true
  - python: "2.7"
    env:
      CRYPTOGRAPHY_GIT_MASTER=true
  - python: "3.2"
    env:
      CRYPTOGRAPHY_GIT_MASTER=true
  - python: "3.3"
    env:
      CRYPTOGRAPHY_GIT_MASTER=true
  - python: "pypy"
    env:
      CRYPTOGRAPHY_GIT_MASTER=true

  # Also run at least a little bit against an older version of OpenSSL.
  - python: "2.7"
    env:
      OPENSSL=0.9.8

  # Let the cryptography master builds fail because they might be triggered by
  # cryptography changes beyond our control.
  allow_failures:
  - env:
      CRYPTOGRAPHY_GIT_MASTER=true
  - env:
      OPENSSL=0.9.8

before_install:
  - if [ -n "$CRYPTOGRAPHY_GIT_MASTER" ]; then pip install git+https://github.com/pyca/cryptography.git;fi

install:
  # Install the wheel library explicitly here.  It is not really a setup
  # dependency.  It is not an install dependency.  It is only a dependency for
  # the script directive below - because we want to exercise wheel building on
  # travis.
  - pip install wheel

  # Also install some tools for measuring code coverage and sending the results
  # to coveralls.
  - pip install coveralls coverage

script:
  - |
    if [[ "${OPENSSL}" == "0.9.8" ]]; then
      sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu/ lucid main"
      sudo apt-get -y update
      sudo apt-get install -y --force-yes libssl-dev/lucid
    fi
  - |
    pip install -e .
  - |
    coverage run --branch --source=OpenSSL setup.py bdist_wheel test
  - |
    coverage report -m
  - |
    python -c "import OpenSSL.SSL; print(OpenSSL.SSL.SSLeay_version(OpenSSL.SSL.SSLEAY_VERSION))"

after_success:
    - coveralls

notifications:
  email: false