def _test_pl_resolve(self, expr1, expr2, expected_symbol):
        sentence1 = PLParser().parse(expr1)
        sentence2 = PLParser().parse(expr2)

        pl_resolution = PLResolution()

        symbol = pl_resolution._pl_resolve(sentence1, sentence2)
        self.assertEquals(expected_symbol, symbol)
    def _test_pl_resolve(self, expr1, expr2, expected_symbol):
        sentence1 = PLParser().parse(expr1)
        sentence2 = PLParser().parse(expr2)

        pl_resolution = PLResolution()

        symbol = pl_resolution._pl_resolve(sentence1, sentence2)
        self.assertEquals(expected_symbol, symbol)
    def _test_resolution(self, expression, question, expected_result):
        kb = KnowledgeBase()
        kb.tell_str(expression)
        question_term = PLParser().parse(question)

        pl_resolution = PLResolution()
        result = pl_resolution.pl_resolution(kb, question_term)
        self.assertEquals(expected_result, result)
    def _test_resolution(self, expression, question, expected_result):
        kb = KnowledgeBase()
        kb.tell_str(expression)
        question_term = PLParser().parse(question)

        pl_resolution = PLResolution()
        result = pl_resolution.pl_resolution(kb, question_term)
        self.assertEquals(expected_result, result)