Add spec coverage for contains_only
Add specific if for contains_only