'``configure_ssh`` writes the remote keypair with secure permissions.'

def test_flocker_keypair_permissions(self):

    configuring = deferToThread(self.configure_ssh, self.server.ip, self.server.port)
    expected_private_key_permissions = Permissions(384)
    expected_public_key_permissions = Permissions(420)
    def configured(ignored):
        expected = (expected_private_key_permissions, expected_public_key_permissions)
        actual = (self.flocker_config.child('id_rsa_flocker').getPermissions(), self.flocker_config.child('id_rsa_flocker.pub').getPermissions())
        self.assertEqual(expected, actual)
    configuring.addCallback(configured)
    return configuring
