Hey Lex, 

To run the tests in PyCharms I followed the following steps: 
1) In Run -> Edit Configurations, I created a new Configuration. 
2) In the script field I gave the path to the runtests.py file and gave 
script parameter as one of the test files since I only wanted to run the 
tests present in one directory.
3) I gave the name as 'runtests'. 

After applying the changes "Run 'runtests' " & "Debug 'runtests' " were 
available in the Run menu. 

Hope that helps. 






On Saturday, December 10, 2016 at 8:05:14 PM UTC+5:30, l...@damoti.com 
wrote:
>
> Hello,
>
> Does anyone here use PyCharm to hack on django? How do you run the unit 
> tests? Specifically, PyCharm has its own runner and django has it's own 
> runner in tests/runtests.py.
>
> It appears that the main thing I need from runtests.py is the settings. Is 
> there a good way to extract the necessary things from runtests.py into a 
> custom settings file so that the django tests could be run without 
> runtests.py (and instead with an IDE)?
>
> My goal is to be able to click on specific tests in the PyCharm IDE and 
> either run or debug them.
>
> Thank you,
>
>  Lex
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/158cd375-a281-4464-890a-de63111f7b9c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to