Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.
 
 
 
 

18 rader
394 B

  1. var Backoff = require('..');
  2. var assert = require('assert');
  3. describe('.duration()', function(){
  4. it('should increase the backoff', function(){
  5. var b = new Backoff;
  6. assert(100 == b.duration());
  7. assert(200 == b.duration());
  8. assert(400 == b.duration());
  9. assert(800 == b.duration());
  10. b.reset();
  11. assert(100 == b.duration());
  12. assert(200 == b.duration());
  13. })
  14. })