nodoherty/ColdFusion-Koans

AboutDates confusing testAddingToDate

jtreher opened this issue · 3 comments

AboutDates confusing testAddingToDate

Is the 'y' day of year datepart really supposed to be here? If these are basic teaching examples, this seems unusual in comparison to the other functions.

public void function testAddingToDate(){
    var myDate = NOW();

    myDate = dateAdd("y",7,myDate);

    assertEquals(dateFormat(myDate,"mm/dd/yyyy"),"12/12/2018");
}

Thanks for opening the issue, I'm super busy ATM but I'll take a look at it as soon as I can!

Thanks for pointing this out, I've committed an updated that changes this to "d" instead of "y"

Sorry, just noticed your pull request was for this issue. Usually they are separate things. I've merged the request.