tests/readlink.py
author Eric Sumner <ericsumner@fb.com>
Tue, 20 Jan 2015 17:38:42 -0800
changeset 24043 1fdb1d909c79
parent 10282 08a0f04b56bd
child 25660 328739ea70c3
permissions -rwxr-xr-x
test-gendoc: require gettext If the gettext utilities aren't installed, there is no way to make the translations. This causes the gettext client to fall back to the untranslated message, which triggers "** NOTHING TRANSLATED **" errors and a test failure.

#!/usr/bin/env python

import errno, os, sys

for f in sys.argv[1:]:
    try:
        print f, '->', os.readlink(f)
    except OSError, err:
        if err.errno != errno.EINVAL:
            raise
        print f, 'not a symlink'

sys.exit(0)