def test_models(self): self.fixtures() results = full_search(self.pw, "felun" , include_entity=True , models=['User'] ) self.assertEqual(results['cant_results'], 1)
def test_fields(self): self.fixtures() results = full_search(self.pw, "felun" , include_entity=True , fields=["name"] ) self.assertEqual(results['cant_results'], 2)
def test_full_search_with_wildcards(self): self.fixtures() found = full_search(self.pw, "fel" , add_wildcards=True , include_entity=True ) self.assertEqual(found['cant_results'], 4)
def test_models(self): self.fixtures() results = full_search(self.pw, "felun", include_entity=True, models=["User"]) self.assertEqual(results["cant_results"], 1)
def test_fields(self): self.fixtures() results = full_search(self.pw, "felun", include_entity=True, fields=["name"]) self.assertEqual(results["cant_results"], 2)
def test_full_search_with_wildcards(self): self.fixtures() found = full_search(self.pw, "fel", add_wildcards=True, include_entity=True) self.assertEqual(found["cant_results"], 4)
def test_full_search_without_wildcards(self): self.fixtures() found = full_search(self.pw, "fel") self.assertEqual(found["cant_results"], 0)
def test_except_field(self): self.fixtures() results = full_search(self.pw, "felun", except_fields=["name"]) self.assertEqual(results["cant_results"], 0)
def test_full_search_without_wildcards(self): self.fixtures() found = full_search(self.pw, "fel") self.assertEqual(found['cant_results'], 0)
def test_except_field(self): self.fixtures() results = full_search(self.pw, "felun", except_fields=["name"]) self.assertEqual(results['cant_results'], 0)