CleanCut / green

Green is a clean, colorful, fast python test runner.
MIT License
793 stars 75 forks source link

Makefile tests failing #152

Closed anomitra closed 7 years ago

anomitra commented 7 years ago

When I clone the repo and run make test, I get this:

File "/home/monto/python-playground/green/green/cmdline.py", line 29, in main
from green.loader import loadTargets
File "green/loader.py", line 13, in <module>
from green.output import debug
File "green/output.py", line 2, in <module>
from colorama.ansi import Cursor
ImportError: No module named colorama.ansi

This is likely due to the fact that Colorama doesn't strip ANSI unless it's running on Windows, and I'm running on Ubuntu 14.04 -- because green green works perfectly and it shows this skipped test

Skipped green.test.test_output.TestGreenStream.testDisableWindowsFalse - Colorama won't strip ANSI unless running on Windows

This seems to be a potential source of confusion. Is it possible to do something about it?

CleanCut commented 7 years ago

I bet there is. I'll take a look at it and see what I can find. Of course, if you figure it out before me, I'd love to accept your pull request. ;-)

CleanCut commented 7 years ago

Sorry for the delay. I finally sat down and took a look at this.

Colorama is an unconditional dependency. It must be installed for Green to function.

The Makefile is mostly intended to automate releasing. I run tests as part of my automated release process. I haven't tried to get any part of it working on a clean box, so I'm not surprised if some things don't work outside my environment.

If you'd like to use the Makefile in your environment, you're welcome to fix it up a bit. I'd be happy to accept any pull requests that make it more portable.