This is an archive of the discontinued LLVM Phabricator instance.

[lldb] [unittests] Disable MainLoopTest::DetectsEOF on NetBSD
ClosedPublic

Authored by mgorny on Feb 7 2019, 10:30 AM.

Details

Summary

The NetBSD kernel currently does not support detecting closed slave pty
via kevent on master pty. This causes the test to hang forever. To
avoid that, disable the test until the kernel is fixed.

Diff Detail

Repository
rL LLVM

Event Timeline

mgorny created this revision.Feb 7 2019, 10:30 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 7 2019, 10:30 AM
mgorny updated this revision to Diff 185815.Feb 7 2019, 10:31 AM
krytarowski accepted this revision.Feb 7 2019, 1:32 PM
This revision is now accepted and ready to land.Feb 7 2019, 1:32 PM
labath accepted this revision.Feb 8 2019, 1:32 AM

I don't remember if this tests some super-critical functionality (i.e., whether you will be able to function reasonably without it), but in case it does, it should be fairly easy to get this class to use one of the other event sources (pselect, ppoll), if kevent is not functioning well on netbsd.

And to answer your IRC question, gtest has a concept of a disabled test, which you do by prefixing the test with "DISABLED_". The typical way to achieve that would be via something like:

#ifdef __NetBSD__
#define SKIP_ON_NETBSD(x) DISABLED_ ## x
#else
#define SKIP_ON_NETBSD(x) x
#endif
TEST(foo, SKIP_ON_NETBSD(bar)) { ... }

However, that is very tedious, so people usually do exactly what you have done here.

mgorny added a comment.Feb 8 2019, 6:06 AM

Ok, thanks. I consider this only temporary; I have a kernel patch ready already (and waiting for review), so we're going to look into reenabling it soon enough.

This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptFeb 8 2019, 10:56 AM

@labath our short-term goal is to enable execution of LLDB tests on the NetBSD buildbot. We are stuck temporarily with an older release of NetBSD on the machine for some time (1-2 months) so we need to live with it for now. No need to make it better than sufficient as of now.