示例#1
0
    def test_has_only_one_result(self):
        """ Tests for the has_only_one_result function """

        self.assertFalse(has_only_one_result([self.searchprovider0]))

        self.assertTrue(has_only_one_result([self.searchprovider0,
                                             self.searchprovider1]))

        self.assertFalse(has_only_one_result([self.searchprovider0,
                                              self.searchprovider1,
                                              self.searchprovider2]))

        self.assertFalse(has_only_one_result([self.searchprovider2]))
示例#2
0
    def test_has_only_one_result(self):
        """ Tests for the has_only_one_result function """

        self.assertFalse(has_only_one_result([self.searchprovider0]))

        self.assertTrue(has_only_one_result([self.searchprovider0,
                                             self.searchprovider1]))

        self.assertFalse(has_only_one_result([self.searchprovider0,
                                              self.searchprovider1,
                                              self.searchprovider2]))

        self.assertFalse(has_only_one_result([self.searchprovider2]))