From commits-return-99558-archive-asf-public=cust-asf.ponee.io@mxnet.incubator.apache.org Wed Sep 4 05:57:25 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 1FE661804BB for ; Wed, 4 Sep 2019 07:57:25 +0200 (CEST) Received: (qmail 6557 invoked by uid 500); 4 Sep 2019 10:03:22 -0000 Mailing-List: contact commits-help@mxnet.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@mxnet.incubator.apache.org Delivered-To: mailing list commits@mxnet.incubator.apache.org Received: (qmail 6548 invoked by uid 99); 4 Sep 2019 10:03:22 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 04 Sep 2019 10:03:22 +0000 From: GitBox To: commits@mxnet.apache.org Subject: [GitHub] [incubator-mxnet] access2rohit commented on a change in pull request #16088: remove 'foo' and other print msg from test Message-ID: <156757664451.5210.17114550146521115169.gitbox@gitbox.apache.org> Date: Wed, 04 Sep 2019 05:57:24 -0000 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit access2rohit commented on a change in pull request #16088: remove 'foo' and other print msg from test URL: https://github.com/apache/incubator-mxnet/pull/16088#discussion_r320583399 ########## File path: tests/python/unittest/test_profiler.py ########## @@ -126,23 +123,25 @@ def makeParams(): template = ''.join('{%d}' % i for i in range(len(objects))) return template, objects - def doLog(): + def get_log(): template, objects = makeParams() + logs = [] for _ in range(100000): - logging.info(template.format(*objects)) + logs.append(template.format(*objects)) + return logs - logging.basicConfig() enable_profiler('test_profile_frame.json') python_domain = profiler.Domain('PythonDomain::test_profile_frame') frame = profiler.Frame(python_domain, "test_profile_frame") frame.start() start = time.time() var = mx.nd.ones((1000, 500)) - doLog() + log = get_log() + assert len(log) == 100000 Review comment: `assert len(get_log()) == 100000` ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: users@infra.apache.org With regards, Apache Git Services