index.js 861 B

1234567891011121314151617181920212223242526272829
  1. 'use strict';
  2. module.exports = function (t, a) {
  3. var queue = t(3);
  4. a(queue.hit('raz'), undefined, "Hit #1");
  5. a(queue.hit('raz'), undefined, "Hit #2");
  6. a(queue.hit('dwa'), undefined, "Hit #3");
  7. a(queue.hit('raz'), undefined, "Hit #4");
  8. a(queue.hit('dwa'), undefined, "Hit #5");
  9. a(queue.hit('trzy'), undefined, "Hit #6");
  10. a(queue.hit('raz'), undefined, "Hit #7");
  11. a(queue.hit('dwa'), undefined, "Hit #8");
  12. a(queue.hit('cztery'), 'trzy', "Overflow #1");
  13. a(queue.hit('dwa'), undefined, "Hit #9");
  14. a(queue.hit('trzy'), 'raz', "Overflow #2");
  15. a(queue.hit('raz'), 'cztery', "Overflow #3");
  16. a(queue.hit('cztery'), 'dwa', "Overflow #4");
  17. a(queue.hit('trzy'), undefined, "Hit #10");
  18. a(queue.hit('dwa'), 'raz', "Overflow #4");
  19. a(queue.hit('cztery'), undefined, "Hit #11");
  20. queue.delete('cztery');
  21. a(queue.hit('cztery'), undefined, "Hit #12");
  22. };