in testSorting(), if the queue put is slow, the consumer would get ahead breaking the test. Instead, wait to consume items until they've all been added