#NEWLINE# def test_next_event_yearly_repeat( self ) : #NEWLINE# #INDENT# create_event ( start_date = ( 2014 , 5 , 3 ) , end_date = ( 2014 , 5 , 6 ) , created_by = self . user , title = 'The Event' , description = 'This is an event. Enjoy.' , repeat = 'YEARLY' ) #NEWLINE# event = Event . objects . all ( ) #NEWLINE# dates = [ [ ( 2014 , 4 , 7 ) , ( 2014 , 5 , 3 ) ] , [ ( 2014 , 5 , 1 ) , ( 2014 , 5 , 3 ) ] , [ ( 2014 , 5 , 7 ) , ( 2015 , 5 , 3 ) ] , [ ( 2015 , 1 , 7 ) , ( 2015 , 5 , 3 ) ] , [ ( 2017 , 5 , 5 ) , ( 2017 , 5 , 5 ) ] ] #NEWLINE# for item in dates : #NEWLINE# #INDENT# now = datetime . datetime ( * item [ 0 ] ) #NEWLINE# ( y , m , d ) = get_next_event ( event , now ) #NEWLINE# self . assertEqual ( ( y , m , d ) , m [ 1 ] )