Random function with Fixes

I read through @nex3's code comments on the random function pull request and implemented the requested changes. I also added some extra tests that weren't requested.

See original pull request here: https://github.com/nex3/sass/pull/968