diff --git a/.github/workflows/unit_tests.yml b/.github/workflows/unit_tests.yml index 9643aa4bcca0..4faad3da158c 100644 --- a/.github/workflows/unit_tests.yml +++ b/.github/workflows/unit_tests.yml @@ -1,7 +1,7 @@ name: easyconfigs unit tests on: [push, pull_request] jobs: - build: + test-suite: runs-on: ubuntu-18.04 strategy: matrix: @@ -119,18 +119,64 @@ jobs: unset PYTHONPATH # install easyconfigs via distribution package - python setup.py sdist + python setup.py sdist > /dev/null ls dist - pip install dist/easybuild-easyconfigs*tar.gz + pip install dist/easybuild-easyconfigs*tar.gz > /dev/null # robot-paths value should not be empty, but have an entry that includes easybuild/easyconfigs subdir + echo "eb --show-config" eb --show-config | tee eb_show_config.out grep "^robot-paths .*/easybuild/easyconfigs" eb_show_config.out + # check whether some specific easyconfig files are found + echo "eb --search 'TensorFlow-1.14.*.eb'" eb --search 'TensorFlow-1.14.*.eb' | tee eb_search_TF.out grep '/TensorFlow-1.14.0-foss-2019a-Python-3.7.2.eb$' eb_search_TF.out - eb --search '^foss-2018b.eb' | tee eb_search_foss.out - grep '/foss-2018b.eb$' eb_search_foss.out + + echo "eb --search '^foss-2019b.eb'" + eb --search '^foss-2019b.eb' | tee eb_search_foss.out + grep '/foss-2019b.eb$' eb_search_foss.out + + # make sure CVS easyconfigs are included in installation (cfr. issue #10325) + echo "Searching for CVS easyconfigs..." + eb --search '^CVS-' | grep '/CVS-' # try installing M4 with system toolchain (requires ConfigureMake easyblock + easyconfig) eb --prefix /tmp/$USER/$GITHUB_SHA M4-1.4.18.eb + + test-sdist: + runs-on: ubuntu-18.04 + strategy: + matrix: + python: [2.7, 3.6, 3.7] + steps: + - uses: actions/checkout@v2 + + - name: set up Python + uses: actions/setup-python@v1 + + - name: Create source distribution + run: python setup.py sdist + + - name: Inspect files included in source distribution + working-directory: dist + run: | + tar xfz easybuild-easyconfigs*tar.gz + cd easybuild-easyconfigs-*/ + + # .git folder should not be there in source tarball + dot_git_files=$(find . -name .git) + if [ -n "$dot_git_files" ]; then + echo "Found .git folders in source tarball: $dot_git_files" && false + else + echo "No .git folders found in source tarball: OK" + fi + + # CVS easyconfigs must be included in source tarball, + # see https://github.com/easybuilders/easybuild-easyconfigs/issues/10325 + cvs_easyconfigs=$(find . -name 'CVS-*.eb') + if [ -z "$cvs_easyconfigs" ]; then + echo "CVS easyconfigs not found" && false + else + echo "Found CVS easyconfigs: $cvs_easyconfigs" + fi diff --git a/.gitignore b/.gitignore index 03b321d42a13..32e6a7345c46 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,4 @@ dist/ *.swp *.ropeproject/ eb-*.log +/MANIFEST diff --git a/MANIFEST.in b/MANIFEST.in index 341e84790266..14e79505f525 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,6 +1,4 @@ -recursive-include easybuild * include CONTRIBUTING.md include LICENSE include README.rst include RELEASE_NOTES -include setup.py diff --git a/setup.cfg b/setup.cfg index 5f7ee1b09010..2866959711d2 100644 --- a/setup.cfg +++ b/setup.cfg @@ -2,3 +2,7 @@ # never install as a zipped egg, since then easyconfig file can't be found zip_ok = 0 + +[sdist] +# Don't remove CVS and RCS directories +prune = 0