Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 43 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,48 @@
language: python
dist: xenial

dist: trusty

compiler:
- gcc

matrix:
include:
- python: '2.7'
- python: '3.5'
- python: '3.6'
- python: '3.7'
# - python: '3.7' # Missing working compile setup for sunbeam
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't let this get into the main branch. Create an issue in the repository instead ;)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A fix before merge is welcome.


before_install:
- python --version
- export CXX="g++-4.9" CC="gcc-4.9"
- export INSTALL_DIR=`pwd`/../install
- export PYTHONPATH=$INSTALL_DIR/lib/python$TRAVIS_PYTHON_VERSION/dist-packages:$PYTHONPATH
- export LD_LIBRARY_PATH=$INSTALL_DIR/lib:$INSTALL_DIR/lib64:$LD_LIBRARY_PATH
- echo $INSTALL_DIR
- echo $PYTHONPATH
- echo $LD_LIBRARY_PATH

addons:
apt:
sources:
- boost-latest
- ubuntu-toolchain-r-test
packages:
- gcc-4.9
- g++-4.9
- libboost1.55-all-dev
- liblapack-dev

sudo: required

install:
- python -m pip install --upgrade pip
- python -m pip install --upgrade -r requirements.txt
- python -m pip install --upgrade -r requirements-dev.txt

before_script:
# For now we have to make install libecl.
# Remove when it's possible to pip install

- source .libecl_version
- git clone https://github.com/equinor/libecl
- pushd libecl
Expand All @@ -45,6 +64,27 @@ before_script:
- rm -rf libecl
- python -c "import ecl; print(ecl.__file__)"

# We also need sunbeam, which requires opm-common:
- git clone --recursive https://github.com/OPM/opm-common.git
- git clone --recursive https://github.com/equinor/sunbeam.git
- mkdir opm-common/build
- pushd opm-common/build
- git checkout release/sunbeam/2019.02
- cmake .. -DCMAKE_PREFIX_PATH=$INSTALL_DIR
-DCMAKE_INSTALL_PREFIX=$INSTALL_DIR
-DBUILD_TESTING=OFF
-DBUILD_SHARED_LIBS=ON
- make -j 4 install
- popd
- mkdir sunbeam/build
- pushd sunbeam/build
- cmake .. -DCMAKE_PREFIX_PATH=$INSTALL_DIR
-DUSE_RPATH=ON
-DCMAKE_INSTALL_PREFIX=$INSTALL_DIR
-DPYTHON_EXECUTABLE=`which python`
- make -j 4 install
- popd

script:
- python setup.py test
- python -m flake8 subscript
1 change: 1 addition & 0 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
pandas
scipy
pyyaml>=5.1
setuptools >=28
setuptools_scm
pytest
Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
pandas
scipy
pyyaml>=5.1
2 changes: 2 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ norecursedirs =
.env
dist
build
opm-common
sunbeam

addopts =
-ra
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
tests_require=["pytest"],
entry_points={
"console_scripts": [
"subscript = subscript.cli:main",
"presentvalue = subscript.presentvalue:main",
"sunsch = subscript.sunsch:main",
]
},
use_scm_version={"write_to": "subscript/version.py"},
Expand Down
Loading