Added more validations
Refactored the version extraction functions into a more dynamic one with tests
Added check for the second argument for getSimpleVersion method with tests
Merge pull request #19 from m0hamed/change_state

refactoring and validations