Add spec for IO#write return value with multibyte strings
Fix return value for IO#write