amqplib 0.5.0 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/lib/channel_model.js +2 -1
- package/package.json +1 -1
- package/test/channel_api.js +7 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# Change log for amqplib
|
|
2
2
|
|
|
3
|
+
## Changes in v0.5.1
|
|
4
|
+
|
|
5
|
+
git log v0.5.0..v0.5.1
|
|
6
|
+
|
|
7
|
+
* Fix mistake in closeBecause
|
|
8
|
+
([PR 298](https://github.com/squaremo/amqp.node/pull/298); thanks
|
|
9
|
+
to @lholznagel and others who reported the issue, and to @nfantone
|
|
10
|
+
for the rapid fix)
|
|
11
|
+
|
|
3
12
|
## Changes in v0.5.0
|
|
4
13
|
|
|
5
14
|
git log v0.4.2..v0.5.0
|
package/lib/channel_model.js
CHANGED
|
@@ -73,8 +73,9 @@ C.open = function() {
|
|
|
73
73
|
};
|
|
74
74
|
|
|
75
75
|
C.close = function() {
|
|
76
|
+
var self = this;
|
|
76
77
|
return Promise.fromCallback(function(cb) {
|
|
77
|
-
return
|
|
78
|
+
return self.closeBecause("Goodbye", defs.constants.REPLY_SUCCESS,
|
|
78
79
|
cb);
|
|
79
80
|
});
|
|
80
81
|
};
|
package/package.json
CHANGED
package/test/channel_api.js
CHANGED
|
@@ -40,7 +40,7 @@ function channel_test(chmethod, name, chfun) {
|
|
|
40
40
|
c[chmethod]().then(ignoreErrors).then(chfun)
|
|
41
41
|
.then(succeed(done), fail(done))
|
|
42
42
|
// close the connection regardless of what happens with the test
|
|
43
|
-
.
|
|
43
|
+
.finally(function() {c.close();});
|
|
44
44
|
});
|
|
45
45
|
});
|
|
46
46
|
}
|
|
@@ -509,6 +509,12 @@ chtest("prefetch", function(ch) {
|
|
|
509
509
|
});
|
|
510
510
|
});
|
|
511
511
|
|
|
512
|
+
chtest('close', function(ch) {
|
|
513
|
+
// Resolving promise guarantees
|
|
514
|
+
// channel is closed
|
|
515
|
+
return ch.close();
|
|
516
|
+
});
|
|
517
|
+
|
|
512
518
|
});
|
|
513
519
|
|
|
514
520
|
var confirmtest = channel_test.bind(null, 'createConfirmChannel');
|