Created
November 4, 2015 17:13
-
-
Save hackebrot/b390c2eda250521b5a17 to your computer and use it in GitHub Desktop.
create pytest tests
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env bash | |
set -e | |
set -u | |
set -x | |
for testdir in foobar hello/world example | |
do | |
mkdir -p $testdir | |
for i in {1..3} | |
do | |
counter=$(printf %02d $i) | |
testfile=$testdir/test_${testdir##*/}_$counter.py | |
echo "def test_sth(): assert True" > $testfile | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment