19.01.2018 01:43, Eric Blake wrote:
On 01/18/2018 12:11 PM, Vladimir Sementsov-Ogievskiy wrote:
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsement...@virtuozzo.com>
---
tests/qemu-iotests/201 | 159 +++++++++++++++++++++++++++++++++++++++++++++
tests/qemu-iotests/201.out | 5 ++
tests/qemu-iotests/group | 1 +
3 files changed, 165 insertions(+)
create mode 100644 tests/qemu-iotests/201
create mode 100644 tests/qemu-iotests/201.out
+
+ def assertExistingClients(self, result):
+ self.assert_qmp(result, 'error/desc',
+ "NBD export 'exp' has 1 active connection. To force "
+ "remove it (and hard disconnect clients) use "
+ "mode='hard'")
Needs tweaking if we massage the error message earlier in the series.
I'm still worried that this test may fail spuriously due to a hard-coded
port, but some testing is better than none, and if the CI engines don't
immediately reject it, whoever first encounters it will be nice and let
us know.
Reviewed-by: Eric Blake <ebl...@redhat.com>
Looked through other tests, looks like same approach is only in 147, and
other iotests uses unix sockets for nbd-server-start. May be, it is
better to move to unix socket here.
I'll resend today with unix-socket.
--
Best regards,
Vladimir