code: def compare(self, node, prev_value=None, prev_index=None):
          
          if prev_value is not None and node.value != prev_value or \
             prev_index is not None and node.index != prev_index:
              raise TestFailed(index=self.index)
docs: Raises :exc:`TestFailed` if the node is not matched with
          `prev_value` or `prev_index`.