is_not_empty() is modified. and testcode is added.