node/test
Tim Wood c9d93f3431 events: don't call once twice
Emitting an event within a `EventEmitter#once` callback of the same
event name will cause subsequent `EventEmitter#once` listeners of the
same name to be called multiple times.

    var emitter = new EventEmitter();

    emitter.once('e', function() {
      emitter.emit('e');
      console.log(1);
    });

    emitter.once('e', function() {
      console.log(2);
    });

    emitter.emit('e');

    // Output
    // 2
    // 1
    // 2

Fix the issue, by calling the listener method only if it was not
already called.
2013-11-13 03:21:04 +04:00
..
addons test: modify async native test.js to test for #4820 2013-02-21 13:14:07 -08:00
disabled Merge remote-tracking branch 'ry/v0.8' into master 2013-02-18 10:21:08 -08:00
fixtures debugger: breakpoints in scripts not loaded yet 2013-05-02 08:52:58 +02:00
gc test: use the debug build of node-weak when necessary 2012-06-13 17:58:28 -07:00
internet test: move two tests from simple/ to internet/ 2013-07-20 12:36:33 +02:00
message process: separate nextTick domain logic 2013-02-27 16:37:10 -08:00
pummel test: use proper findjsobjects output format 2013-10-10 15:45:25 -07:00
simple events: don't call once twice 2013-11-13 03:21:04 +04:00
common.js test: optionally set common.PORT via env variable 2013-03-02 19:09:39 +01:00