Skip to content

Commit 80d136a

Browse files
committed
Add test & documentation for replicationStart message
1 parent 4f790de commit 80d136a

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ For richer information consult the commit log on github with referenced pull req
44

55
We do not include break-fix version release in this file.
66

7+
### v6.2.0
8+
9+
- Add support for [parsing `replicationStart` messages](https://github.com/brianc/node-postgres/pull/1271/files).
10+
711
### v6.1.0
812

913
- Add optional callback parameter to the pure JavaScript `client.end` method. The native client already supported this.

test/unit/connection/inbound-parser-tests.js

+7-1
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,13 @@ test('Connection', function() {
347347
name: 'portalSuspended'
348348
});
349349
});
350+
351+
test('parses replication start message', function() {
352+
testForMessage(new Buffer([0x57, 0x00, 0x00, 0x00, 0x04]), {
353+
name: 'replicationStart',
354+
length: 4
355+
});
356+
});
350357
});
351358

352359
//since the data message on a stream can randomly divide the incomming
@@ -465,5 +472,4 @@ test('split buffer, multiple message parsing', function() {
465472
splitAndVerifyTwoMessages(1);
466473
});
467474
});
468-
469475
});

0 commit comments

Comments
 (0)