#NEWLINE# def test_enqueue_at( self ) : #NEWLINE# #INDENT# d = ( datetime . datetime . now ( ) + datetime . timedelta ( days = 1 ) ) #NEWLINE# d2 = ( d + datetime . timedelta ( days = 1 ) ) #NEWLINE# key = int ( time . mktime ( d . timetuple ( ) ) ) #NEWLINE# key2 = int ( time . mktime ( d2 . timetuple ( ) ) ) #NEWLINE# self . resq . enqueue_at ( d , Basic , 'test1' ) #NEWLINE# self . resq . enqueue_at ( d , Basic , 'test2' ) #NEWLINE# assert ( self . redis . llen ( ( 'resque:delayed:%s' % key ) ) == 2 ) #NEWLINE# assert ( len ( self . redis . zrange ( 'resque:delayed_queue_schedule' , 0 , 20 ) ) == 1 ) #NEWLINE# self . resq . enqueue_at ( d2 , Basic , 'test1' ) #NEWLINE# assert ( self . redis . llen ( ( 'resque:delayed:%s' % key2 ) ) == 1 ) #NEWLINE# assert ( len ( self . redis . zrange ( 'resque:delayed_queue_schedule' , 0 , 20 ) ) == 2 )