Fixing tests in old versions of perl

I hope this commit should fix this error:
https://travis-ci.org/bessarabov/Moment/jobs/43020947