/**
  * A method to test the dates returned by the _getSpanDates()
  * method when used with the 'friendly' preset "last_month".
  */
 function test_getSpanDatesLastMonth()
 {
     $oDaySpan = new OA_Admin_DaySpan();
     $oDaySpan->oNowDate = new Date('2007-05-09');
     $aDates = $oDaySpan->_getSpanDates('last_month');
     $this->assertEqual($aDates['start']->format('%Y-%m-%d'), '2007-04-01');
     $this->assertEqual($aDates['end']->format('%Y-%m-%d'), '2007-04-30');
     $oDaySpan->oNowDate = new Date('2007-05-10');
     $aDates = $oDaySpan->_getSpanDates('last_month');
     $this->assertEqual($aDates['start']->format('%Y-%m-%d'), '2007-04-01');
     $this->assertEqual($aDates['end']->format('%Y-%m-%d'), '2007-04-30');
 }