Improve example test script (with failing example)
This commit is contained in:
parent
c6992da123
commit
2aa631f4e6
@ -4,7 +4,9 @@ language: python
|
||||
python: 3.8
|
||||
cache:
|
||||
directories:
|
||||
- "$HOME/.cache/pip"
|
||||
- "./tests/artifacts"
|
||||
- "$HOME/datasets"
|
||||
install:
|
||||
- pip install git+git://github.com/si-cim/prototorch@dev --progress-bar off
|
||||
- pip install .[all] --progress-bar off
|
||||
|
@ -4,7 +4,8 @@ import argparse
|
||||
|
||||
import prototorch as pt
|
||||
import pytorch_lightning as pl
|
||||
import torch
|
||||
|
||||
#import torch
|
||||
|
||||
if __name__ == "__main__":
|
||||
# Command-line arguments
|
||||
|
@ -1,10 +1,17 @@
|
||||
#! /bin/bash
|
||||
|
||||
failed=0
|
||||
|
||||
for example in $(find $1 -maxdepth 1 -name "*.py")
|
||||
do
|
||||
echo "test:" $example
|
||||
export DISPLAY= && python $example --fast_dev_run 1
|
||||
echo -n "$x" $example '... '
|
||||
export DISPLAY= && python $example --fast_dev_run 1 &> /dev/null
|
||||
if [[ $? -ne 0 ]]; then
|
||||
exit 1
|
||||
echo "Failed!!!!"
|
||||
failed=1
|
||||
else
|
||||
echo "Success."
|
||||
fi
|
||||
done
|
||||
|
||||
exit $failed
|
Loading…
Reference in New Issue
Block a user