Return-Path: Delivered-To: apmail-hadoop-mapreduce-issues-archive@minotaur.apache.org Received: (qmail 22111 invoked from network); 7 Oct 2009 17:19:04 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 7 Oct 2009 17:19:04 -0000 Received: (qmail 52376 invoked by uid 500); 7 Oct 2009 17:19:04 -0000 Delivered-To: apmail-hadoop-mapreduce-issues-archive@hadoop.apache.org Received: (qmail 52337 invoked by uid 500); 7 Oct 2009 17:19:04 -0000 Mailing-List: contact mapreduce-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: mapreduce-issues@hadoop.apache.org Delivered-To: mailing list mapreduce-issues@hadoop.apache.org Received: (qmail 52327 invoked by uid 99); 7 Oct 2009 17:19:04 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Oct 2009 17:19:04 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Oct 2009 17:18:52 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 581F1234C1EC for ; Wed, 7 Oct 2009 10:18:31 -0700 (PDT) Message-ID: <558429534.1254935911333.JavaMail.jira@brutus> Date: Wed, 7 Oct 2009 10:18:31 -0700 (PDT) From: "Chad Metcalf (JIRA)" To: mapreduce-issues@hadoop.apache.org Subject: [jira] Commented: (MAPREDUCE-1050) Introduce a mock object testing framework In-Reply-To: <182552465.1254414683622.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/MAPREDUCE-1050?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12763138#action_12763138 ] Chad Metcalf commented on MAPREDUCE-1050: ----------------------------------------- +1 on mockito Couple of nice comparisons to easymock. http://blog.jteam.nl/2009/08/13/easier-mocking-with-mockito/ http://code.google.com/p/mockito/wiki/MockitoVSEasyMock The jmock guys acknowledge that their tool is opinionated and the structure arcane but that they made those decisions to force test in a certain direction. That is all fine and well for a company that can devote time and resources to training. I think its less appropriate on an open source project. I think mockito would be a good choice in this environment (lots of developers from different backgrounds, testing training, etc). In the end we want people to use the tool and test. > Introduce a mock object testing framework > ----------------------------------------- > > Key: MAPREDUCE-1050 > URL: https://issues.apache.org/jira/browse/MAPREDUCE-1050 > Project: Hadoop Map/Reduce > Issue Type: Test > Components: test > Reporter: Tom White > Assignee: Tom White > Attachments: MAPREDUCE-1050.patch > > > Using mock objects in unit tests can improve code quality (see e.g. http://www.mockobjects.com/). Hadoop would benefit from having a mock object framework for developers to write unit tests with. Doing so will allow a wider range of failure conditions to be tested and the tests will run faster. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.