From fc14af14e62a0398fb7e263b646ba89421343ee0 Mon Sep 17 00:00:00 2001 From: Robert Bradshaw Date: Tue, 23 Feb 2010 22:10:00 -0800 Subject: [PATCH] Remove benchmark from tests. --- tests/run/dict_getitem.pyx | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) diff --git a/tests/run/dict_getitem.pyx b/tests/run/dict_getitem.pyx index 1e063da3..b465a5b8 100644 --- a/tests/run/dict_getitem.pyx +++ b/tests/run/dict_getitem.pyx @@ -29,24 +29,6 @@ def test(dict d, index): """ return d[index] -def time_dict(dict d, ix, long N): - """ - >>> time_dict({"abc": 1}, "abc", 1e6) - """ - from time import time - t = time() - cdef int i - for i in range(N): - d[ix] - return time() - t - -def time_nondict(object d, ix, long N): - """ - >>> time_nondict({"abc": 1}, "abc", 1e6) - """ - from time import time - t = time() - cdef int i - for i in range(N): - d[ix] - return time() - t +cdef class Subscriptable: + def __getitem__(self, key): + return key \ No newline at end of file -- 2.26.2