[RFC] Adding unit test for rlibc

We are pulling in rlibc into Zinc (hackndev/zinc#113), but while reading the code, I though it could do with some unit tests.

So I have added some tests here, but seem like there are a few issues... Please see comments with `XXX` and respond if you have any thoughts :+1:
This isn't necessary anymore, since there are now other tests: this workaround for #10872/https://github.com/rust-lang/rust/issues/13793 works by just ensuring that there is at least one `#[test]` in the crate.