updated test to iterate through entire queue
implemeneted priority queue for exercise 4.2