Ticket #355: bin-tests.diff

File bin-tests.diff, 1.3 KB (added by jinmei, 9 years ago)
  • process_rename_test.py.in

     
    4949            re.MULTILINE)
    5050
    5151        # Find all Makefile.in and extract names of scripts
    52         for (d, _, fs) in os.walk('@top_srcdir@'):
     52        for (d, _, fs) in os.walk('@top_builddir@'):
    5353            if 'Makefile.in' in fs:
    5454                makefile = ''.join(open(os.path.join(d,
    5555                    "Makefile.in")).readlines())
  • Makefile.am

     
    11PYTESTS = process_rename_test.py
    2 EXTRA_DIST = $(PYTESTS)
     2# .py will be generated by configure, so we don't have to include it
     3# in EXTRA_DIST.
    34
    45# later will have configure option to choose this, like: coverage run --branch
    56PYCOVERAGE = $(PYTHON)
     
    89        for pytest in $(PYTESTS) ; do \
    910        echo Running test: $$pytest ; \
    1011        env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/python/.libs \
    11         $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
     12        $(PYCOVERAGE) $(abs_builddir)/$$pytest || exit ; \
    1213        done