Added tests for hookCommand

This PR fixes a small bug on windows and adds more unit tests for the uniter.
the version.Current.OS field also allws us to behave differently on several possible future linux distros we may support. If we simply do a runtime.GOOS on CentOS and on Ubuntu you will get the same output, but you may want to behave differently (yum vs apt-get for example).