2 # -*- coding: utf-8 -*-
4 # file src/tex2lyx/test/runtests.py
5 # This file is part of LyX, the document processor.
6 # Licence details can be found in the file COPYING.
10 # Full author contact details are available in file CREDITS
12 # This script reads a unicode symbol file and completes it in the given range
14 import os, string, sys
18 return "Usage: %s [<tex2lyx binary>]" % prog_name
22 # Parse and manipulate the command line arguments.
23 sys.path.append(os.path.join(os.path.dirname(sys.argv[0]), '../../../lib/scripts'))
24 from lyxpreview_tools import error
33 basedir = os.path.dirname(argv[0])
35 files = ['test.ltx', 'test-structure.tex', 'test-insets.tex', \
36 'box-color-size-space-align.tex', 'CJK.tex', \
37 'XeTeX-polyglossia.tex']
40 texfile = os.path.join(os.path.dirname(argv[0]), f)
41 cmd = '%s -roundtrip -f %s' % (tex2lyx, texfile)
42 if os.system(cmd) != 0:
43 error('Running `%s´ failed.' % cmd)
46 if __name__ == "__main__":