Merge pull request #6 from lazytiger/master

add InstaceTemplate and test