Writing some tests for new feature

64 views
Skip to first unread message

ST LEON

unread,
Apr 22, 2015, 12:46:31 PM4/22/15
to django-d...@googlegroups.com
I want to contribute one new feature to Django (doing this first time).

I reading this and have one question.

First, write tests. I want to improve work of ping_google() and add some new behavior. 

But I can't find any tests that cover this function. 

I think, that it might be here, but I can't find tests for ping_google().

So, what should I do? That test needs me to see, how they works, change some of them and write new ones.

My changes aren't be so serious: just a very simple 2-3 new lines.

Please, help. 

Thanks!

Marc Tamlyn

unread,
Apr 22, 2015, 2:02:27 PM4/22/15
to django-d...@googlegroups.com
It's quite possible this is an area which is untested - partly because when it was originally written we didn't have the mock library to prevent the external url call. Adding tests would be wonderful.

Marc

--
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-develop...@googlegroups.com.
To post to this group, send email to django-d...@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/474b740a-adb2-4c72-b297-e91941bc3e63%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Tim Graham

unread,
Apr 22, 2015, 2:29:42 PM4/22/15
to django-d...@googlegroups.com
I'll copy my reply from your django-users thread in case you didn't see it:

There was some recent work done on allowing customizing the ping_google sitemap URL, but it wasn't completed: https://github.com/django/django/pull/3528

You could take inspiration from your tests from there.
Reply all
Reply to author
Forward
0 new messages