testing memoize functions