added tests to check for non numbers and in the correct range