def testCreateTestsWeighted(self):
    b = benchmark.Benchmark([mocks.MockNameServer(mocks.GOOD_IP)],
                            test_count=1000)
    results = b.CreateTests(('google.com', 'live.com'))
    self.assertEquals(len(results), 1000)
    self.assertTrue(('A', 'www.google.com.') in results)
    caches = [x for x in results if 'cache' in x[1]]
    self.assertTrue(len(caches) > 0 and 50 < len(caches))
dataset/ETHPy150Open catap/namebench/libnamebench/benchmark_test.py/BenchmarkTest.testCreateTestsWeighted/swapped operands of `<`