django unit testing timezone

Viewed 16

In my settings.py I have implemented timezone as

TIME_ZONE = os.environ.get("TIMEZONE", "Europe/London")

I've tried something like

    assert timezone.localtime() == timezone.get_current_timezone()

    print(timezone.localtime())
    print(timezone.get_current_timezone())

How would I change get_current_timezone so that it could be compared to localtime

0 Answers
Related