Test both empty and non-empty strings