We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3fe6d4e commit ae9d527Copy full SHA for ae9d527
test/socket.io.js
@@ -1291,6 +1291,24 @@ describe('socket.io', function(){
1291
});
1292
1293
1294
+
1295
+ it('deletes empty rooms', function(done) {
1296
+ var srv = http();
1297
+ var sio = io(srv);
1298
1299
+ srv.listen(function(){
1300
+ var socket = client(srv);
1301
+ sio.on('connection', function(s){
1302
+ s.join('a', function(){
1303
+ expect(s.nsp.adapter.rooms).to.have.key('a');
1304
+ s.leave('a', function(){
1305
+ expect(s.nsp.adapter.rooms).to.not.have.key('a');
1306
+ done();
1307
+ });
1308
1309
1310
1311
1312
1313
1314
describe('middleware', function(done){
0 commit comments