On Tue, 18 Oct 2022 14:33:29 -0600 Scott Furry <
scott.w...@gmail.com> wrote:
SF> On 2022-10-18 07:59, Vadim Zeitlin wrote:
SF> > SF> Platform: Linux x86_64(Gentoo)
SF> > SF> Clang/LLVM: 13.0.1
SF> > SF> libxml2: 2.10.3
SF> > SF> libxslt: 1.1.37
SF> > SF> xmlwrapp: git head (4bcdbd633a9c37ec74b527e053ffdd34c669291a)
SF> > SF>
SF> > SF> autoreconf and compile w/o error using clang/clang++.
SF> >
SF> > Hi Scott,
SF> >
SF> > SF> Executing tests on the command line, problems were encountered when
SF> > SF> excuting the test regime outside of the `xmlwrapp/tests` directory. Paths
SF> > SF> are not resolved to find `xmlwrapp/tests/attributes/data` directory.
SF> >
SF> > The tests resolve paths relative to "srcdir" environment variable, see
SF> >
SF> >
https://github.com/vslavik/xmlwrapp/blob/4bcdbd633a9c37ec74b527e053ffdd34c669291a/tests/test_main.cxx#L43
SF> >
SF> > so it can (and must) be set when running them from another directory. I'm
SF> > not sure it's really worth improving this except for, maybe, giving a
SF> > better error explaining this if the files are not found.
[...]
SF> I'll take a swing at this a little latter.
Sorry, I'm not sure it's the same situation. It's not a question of not
using std::filesystem, but of actually needing some outside help for
finding the files because the test, located in the build directory, simply
can't know where they are without this.
The alternative is to copy the files to the build directory, but I'm not
sure it's such a great idea neither.
SF> > SF> After cd into `xmlwrapp/tests`, executing `test` produced incomplete
SF> > SF> results. It appears that testing did not run to the end but with a SIGSEGV
SF> > SF> on `node/test_node.cxx:264`.
SF> >
SF> > This looks very much like
https://github.com/vslavik/xmlwrapp/pull/77
SF> > could you please confirm that applying it fixes the problem for you too?
SF> > If so, it should be merged, even though I still don't understand neither
SF> > why I don't see it nor why does this fix work.
SF> Applying the suggested code (commit ID
SF> cef8547f78deabb3588be5fad202dbe12df6a93c)
SF> results in testing running successfully to completion.
Thanks!
SF> > I'd just like to ask if running only the "node/replace" test crashes on
SF> > its own, or does it need to be run as part of the full test suite to see
SF> > the crash? Also, if you can rebuild it with -fsanitize=address and check if
SF> > you get anything useful from ASAN when running this test, please let me
SF> > know!
SF> I'll attempt ASAN testing a little latter today and report back.
TIA, I'd really like to understand what's going on here because I just
don't know why I don't see the problem. FWIW I've tested with clang 13.1.6
under macOS and 13.0.1 and 14.0.6 under Debian and the tests stubbornly
pass for me with all of them...
VZ