Add gradle support and test