From 9a24a11279ab021d592edaec12fa4bd5fec89975 Mon Sep 17 00:00:00 2001 From: Ajay Poshak Date: Mon, 8 Jul 2019 17:21:14 +0530 Subject: [PATCH] Add more tests to check default priority --- test.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/test.js b/test.js index 2824dae..ee00268 100644 --- a/test.js +++ b/test.js @@ -16,4 +16,13 @@ console.assert(pq.peek() === null) pq.clear() -console.assert(pq.dequeue() === null) \ No newline at end of file +console.assert(pq.dequeue() === null) + +pq.queue(51) +pq.queue(52) +pq.queue(53) +pq.queue(54, 2) +console.assert(pq.dequeue() === 54) +console.assert(pq.dequeue() === 51) +console.assert(pq.dequeue() === 52) +console.assert(pq.dequeue() === 53) \ No newline at end of file