This adds a test for closing the `pqueue` while the `pqueue` contains data that has not yet been dequeued. This issue was found while debugging #6705 This test will fail until @cmwaters fix for this condition is merged.