So I stay in South Africa and we do not observe DST at all. So, my code would always say DST is not on - which is correct. However, if this was a real-world application, I would want to make sure my code works properly.
So on the Mac I changed my time zone to a country that observed DST and then re-ran my program.
This showed me the code works perfectly.
Just a small tip.