Add weeks function and test