fix bug with semantic version and added tests