Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Skip (portions of) tests that do not work as root #5020
James McCoy wrote:
Added IsRoot() function to check for root, so that portions of a test can be skipped, and :CheckNotRoot to entirely skip a test.
I discourage running tests as root. Just as it's discourages to build programs as root. Would it be OK to bail out of tests completely? Why are tests being run as root?…
-- ROBIN: The what? ARTHUR: The Holy Hand Grenade of Antioch. 'Tis one of the sacred relics Brother Maynard always carries with him. ALL: Yes. Of course. ARTHUR: (shouting) Bring up the Holy Hand Grenade! "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///
This is happening in a throw away container. I could go through the extra steps of setting up a non-root user, making the data accessible to that user, running the tests from there, but that's just unnecessary scaffolding.