[RFC] fix unittest issues with busted 2.x

Marking this RFC because other than cleaning up the commit messages (and squashing), I don't plan to do much else.

Followup of https://github.com/neovim/neovim/pull/1098#issuecomment-54712118

This is on top of @fwalch's commit because these scoping issues don't occur with busted 1.x.

Regardless of what's going on with busted, it's probably a good thing to avoid global scope. 

There's also some other weird issues that came up that I'm not sure are related to busted: they could be caused by other included packages such as penlight (I didn't investigate this though).

ping @fwalch @tarruda 

ping @aktau because this touches the lua C preprocessor and I'm hoping there's a chance you might have a clue why `popen()` is being weird.
What error did Lua give to provoke this change, if I may inquire?