':py:obj:`OpenSSL.rand.write_file` raises :py:obj:`TypeError` when called with the
wrong number of arguments or a non-:py:obj:`str` argument.'

def test_write_file_wrong_args(self):

    self.assertRaises(TypeError, rand.write_file)
    self.assertRaises(TypeError, rand.write_file, None)
    self.assertRaises(TypeError, rand.write_file, 'foo', None)
