more comprehensive tests for connection closing