':py:obj:`Context.use_certificate_file` raises :py:obj:`TypeError` if
called with zero arguments or more than two arguments, or if the first
argument is not a byte string or the second argumnent is not an integer.'

def test_use_certificate_file_wrong_args(self):

    ctx = Context(TLSv1_METHOD)
    self.assertRaises(TypeError, ctx.use_certificate_file)
    self.assertRaises(TypeError, ctx.use_certificate_file, 'somefile', object())
    self.assertRaises(TypeError, ctx.use_certificate_file, 'somefile', FILETYPE_PEM, object())
    self.assertRaises(TypeError, ctx.use_certificate_file, object(), FILETYPE_PEM)
    self.assertRaises(TypeError, ctx.use_certificate_file, 'somefile', object())
