def finished(self):
        """Checks if the History matches with a finished Workflow
        Execution history state.
        """
        completion_states = (
            'completed',
            'failed',
            'canceled',
            'terminated'
        )

        if (isinstance(self.last, WorkflowExecutionEvent) and
            self.last.state in completion_states):
            return True

        return False