adding tests + functionality for build