'Test that channel open failure packets cause the channel to be
notified that its opening failed.'

def test_CHANNEL_OPEN_FAILURE(self):

    channel = TestChannel()
    self.conn.openChannel(channel)
    self.conn.ssh_CHANNEL_OPEN_FAILURE(('\x00\x00\x00\x00\x00\x00\x00\x01' + common.NS('failure!')))
    self.assertEqual(channel.openFailureReason.args, ('failure!', 1))
    self.assertIsNone(self.conn.channels.get(channel))
