Question 1.8 test cases in Swift

These are the test cases that should pass in order for the solution to be
considered correct. The method should be implemented as a class extension of
NSString and should return a Bool.