Ensures :attr:`subject` contains all of *elements*, which must be an iterable, and no other items.

def contains_only(self, elements):
        """
        Ensures :attr:`subject` contains all of *elements*, which must be an iterable, and no other items.
        """
        for element in self._subject:
            if element not in elements:
                raise self._error_factory(_format("Expected {} to have only {}, but it contains {}",
                                                  self._subject, elements, element))
        self.contains_all_of(elements)
        return ChainInspector(self._subject)