When I need to set the date to a known day for tests, I use
forbiddenfruit (https://github.com/clarete/forbiddenfruit).
On Wed, 2017-01-25 at 20:46 +0100, Carsten Fuchs wrote:
> Dear Django fellows,
> 
> I'm using LiveServerTestCase with Selenium. The application code run
> by 
> LiveServerTestCase's live server works well and a view's call to
> date.today() 
> returns the current date.
> 
> For the tests, however, it would be helpful if we could fix the time
> and date at 
> which the test is supposedly run, making date.today() and similar
> functions 
> return a predetermined value.
> 
> Can this be achieved?
> 
> Best regards,
> Carsten
> 
-- 
Adam (a...@csh.rit.edu)


-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/1485374467.29427.53.camel%40csh.rit.edu.
For more options, visit https://groups.google.com/d/optout.

Reply via email to