Skip to content

Commit

Permalink
Merge pull request #17 from octodns/cibuild-setup-py-fix
Browse files Browse the repository at this point in the history
Rework cibuild-setup-py to build a pkg and install & test
  • Loading branch information
ross authored Apr 18, 2024
2 parents 37f3b82 + 668a244 commit 1fbeb52
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions script/cibuild-setup-py
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,20 @@ set -e

cd "$(dirname "$0")/.."

VERSION="$(grep "^__version__" "./octodns_spf/__init__.py" | sed -e "s/.* = '//" -e "s/'$//")"

echo "## create test venv ############################################################"
TMP_DIR=$(mktemp -d -t ci-XXXXXXXXXX)
python3 -m venv $TMP_DIR
. "$TMP_DIR/bin/activate"
pip install setuptools
pip install build setuptools
echo "## environment & versions ######################################################"
python --version
pip --version
echo "## validate setup.py build #####################################################"
python setup.py build
echo "## validate setup.py install ###################################################"
python setup.py install
echo "## installed module versions ###################################################"
pip freeze
python -m build --sdist --wheel
echo "## validate wheel install ###################################################"
pip install dist/*$VERSION*.whl
echo "## validate tests can run against installed code ###############################"
pip install pytest pytest-network
pytest --disable-network
Expand Down

0 comments on commit 1fbeb52

Please sign in to comment.