Commits

Doug Hellmann committed 6800f8b

fix template listing for python 2.4, which does not support the -m option with namespace packages

Comments (0)

Files changed (2)

tests/test_project_templates.sh

 
 test_list_templates () {
     output=$(mkproject -h 2>&1)
-    assertTrue "Did not find test template in \"$output\"" "echo \"$output\" | grep -q test"
+    assertTrue "Did not find test template in \"$output\"" "echo \"$output\" | grep -q 'Creates a test file'"
 }
 
 test_apply_template () {

virtualenvwrapper.sh

     echo
     echo "Available project templates:"
     echo
-    "$VIRTUALENVWRAPPER_PYTHON" -m virtualenvwrapper.hook_loader -l project.template
+    "$VIRTUALENVWRAPPER_PYTHON" -c 'from virtualenvwrapper.hook_loader import main; main()' -l project.template
 }
 
 # Create a new project directory and its associated virtualenv.