Skip to content
Snippets Groups Projects
Commit aebd8e62 authored by Janet Goldstein's avatar Janet Goldstein
Browse files

Merge pull request #18 in SSA/data from SSA-6324-pytest-branch3-modules-and-scodeup to main

* commit '798426a8':
  SSA-6324: fixes locking message problem discovered in SSA-6458
  SSA-6324: refactored prop setter for testability and created tests; added script to run all tests in data repo
  Remove unittest from datafetcher and migrate to pytest
  Remove unittest from test_updater.py, rely on pytest instead
  Tests work, remove src imports
parents 99fbb9e9 798426a8
No related branches found
No related tags found
No related merge requests found
......@@ -6,19 +6,18 @@
TOP_LEVEL=/Users/jgoldste/Projects/data/
cd $TOP_LEVEL
current_env=$CONDA_DEFAULT_ENV
if [ -z $current_env ]
if [ -z $CONDA_DEFAULT_ENV ]
then
echo '>>> Updating conda environment....'
conda env update
echo '>>> Activating....'
conda activate data
else
echo "conda environment 'data' is active"
echo "conda environment '${CONDA_DEFAULT_ENV}' is active"
fi
SETUP=setup.py
echo '>>> finding all $SETUP'
echo ">>> looking for ${SETUP} in all modules...."
SETUPS=$(find . -name $SETUP -exec echo '{}' \;)
for item in $SETUPS
do
......@@ -27,8 +26,6 @@ do
cd ${dir}
python setup.py develop
# to_keep=$(basename -s $item)
# echo $to_keep
done
#!/bin/bash
# Set up conda environment, if necessary,
# then in each module:
# 1. run setup
# 2. if there is a test/ subdirectory, execute pytest therein
TOP_LEVEL=/Users/jgoldste/Projects/data/
cd $TOP_LEVEL
if [ -z $CONDA_DEFAULT_ENV ]
then
echo '>>> Updating conda environment....'
conda env update
echo '>>> Activating....'
conda activate data
else
echo "conda environment '${CONDA_DEFAULT_ENV}' is active"
fi
SETUP=setup.py
echo ">>> looking for ${SETUP} in all modules...."
SETUPS=$(find . -name $SETUP -exec echo '{}' \;)
for item in $SETUPS
do
dir=$(dirname $item)
dir=${TOP_LEVEL}${dir:1}
cd ${dir}
if [ -z $? ]
then
exit $?
fi
echo ">>> running ${SETUP} in ${dir}...."
python setup.py develop
if [ -d $dir/test ]
then
cd test
pytest --log-level=DEBUG --showlocals
fi
done
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment