diff --git a/.circleci/config.yml b/.circleci/config.yml index 2aa60ca444..fb0f2ed246 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,62 +1,93 @@ -version: 2 +version: 2.1 + +commands: + install-packaged-featuretools: + description: "install featuretools from source distribution" + steps: + - run : | + source test_env/bin/activate + python setup.py sdist + FEATURETOOLS_VERSION=$(python setup.py --version) + tar -zxvf "dist/featuretools-${FEATURETOOLS_VERSION}.tar.gz" + pip install -e "featuretools-${FEATURETOOLS_VERSION}/" + pip install -r "featuretools-${FEATURETOOLS_VERSION}/test-requirements.txt" + run-packaged-tests: + description: "run unit tests on packaged testing files" + steps: + - run: | + source test_env/bin/activate + cd "featuretools-$(python setup.py --version)/" + pytest + jobs: - "python-2.7": + "python-27": working_directory: ~/featuretools docker: - - image: circleci/python:2.7 + - image: circleci/python:2.7 steps: - run: sudo apt update && sudo apt install -y graphviz - checkout - - run: virtualenv venv - - run: source venv/bin/activate && make installdeps - - run: source venv/bin/activate && make lint - - run: source venv/bin/activate && make test + - run: virtualenv test_env && virtualenv dev_env + - install-packaged-featuretools + - run: source dev_env/bin/activate && make installdeps + - run: source dev_env/bin/activate && make lint + - run-packaged-tests - "python-3.5": + "python-35": working_directory: ~/featuretools docker: - - image: circleci/python:3.5 + - image: circleci/python:3.5 steps: - run: sudo apt update && sudo apt install -y graphviz - checkout - - run: virtualenv venv - - run: source venv/bin/activate && make installdeps - - run: source venv/bin/activate && make lint - - run: source venv/bin/activate && make test + - run: virtualenv test_env && virtualenv dev_env + - install-packaged-featuretools + - run: source dev_env/bin/activate && make installdeps + - run: source dev_env/bin/activate && make lint + - run-packaged-tests - "python-3.6": + "python-36": working_directory: ~/featuretools docker: - - image: circleci/python:3.6 + - image: circleci/python:3.6 steps: - run: sudo apt update && sudo apt install -y graphviz pandoc - checkout - - run: virtualenv venv - - run: source venv/bin/activate && make installdeps - - run: source venv/bin/activate && make lint - - run: source venv/bin/activate && make -C docs/ -e "SPHINXOPTS=-W" clean html - - run: | - source venv/bin/activate - coverage erase - make testcoverage && codecov + - run: virtualenv test_env && virtualenv dev_env + - install-packaged-featuretools + - run: source dev_env/bin/activate && make installdeps + - run: source dev_env/bin/activate && make lint + - run-packaged-tests + - run: source dev_env/bin/activate && make -C docs/ -e "SPHINXOPTS=-W" clean html - "python-3.7": + "python-37": working_directory: ~/featuretools docker: - - image: circleci/python:3.7 + - image: circleci/python:3.7 steps: - run: sudo apt update && sudo apt install -y graphviz - checkout - - run: virtualenv venv - - run: source venv/bin/activate && make installdeps - - run: source venv/bin/activate && make lint - - run: source venv/bin/activate && make test + - run: virtualenv test_env && virtualenv dev_env + - install-packaged-featuretools + - run: source dev_env/bin/activate && make installdeps + - run: source dev_env/bin/activate && make lint + - run: | + source test_env/bin/activate + pip install "$(cat dev-requirements.txt | grep codecov)" + coverage erase + FEATURETOOLS_VERSION=$(python setup.py --version) + cd "featuretools-${FEATURETOOLS_VERSION}/" + coverage erase + pytest featuretools/tests --cov=featuretools --cov-config=../.coveragerc + cd ../ + cp "featuretools-${FEATURETOOLS_VERSION}/.coverage" .coverage + codecov workflows: version: 2 test_all_python_versions: jobs: - - "python-2.7" - - "python-3.5" - - "python-3.6" - - "python-3.7" + - "python-27" + - "python-35" + - "python-36" + - "python-37" diff --git a/test-requirements.txt b/test-requirements.txt index 60161361c4..44b705d6a8 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -3,7 +3,6 @@ mock==2.0.0 pympler==0.5 pytest-xdist==1.26.1 pytest-cov==2.6.1 -llvmlite==0.27.0 fastparquet>=0.1.6 graphviz>=0.8.4 s3fs>=0.1.5