def test_exact_prepare(self): exact = inputs.Exact("hello OR there, :you") self.assertEqual(exact.prepare(self.query_obj), '"hello OR there, :you"') # Incorrect, but the backend doesn't implement much of anything useful. exact = inputs.Exact("hello OR there, :you", clean=True) self.assertEqual(exact.prepare(self.query_obj), '"hello OR there, :you"')
def test_exact_prepare(self): exact = inputs.Exact('hello OR there, :you') self.assertEqual(exact.prepare(self.query_obj), u'"hello OR there, :you"') exact = inputs.Exact('hello OR there, :you', clean=True) self.assertEqual(exact.prepare(self.query_obj), u'"hello or there, \\:you"')
def test_exact_init(self): exact = inputs.Exact('hello OR there, :you') self.assertEqual(exact.query_string, 'hello OR there, :you') self.assertEqual(exact.post_process, True)
def test_exact_prepare(self): exact = inputs.Exact("hello OR there, :you") self.assertEqual(exact.prepare(self.query_obj), '"hello OR there, :you"')