Return-Path: X-Original-To: apmail-incubator-kafka-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-kafka-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B522B9C6F for ; Sun, 6 Nov 2011 06:50:43 +0000 (UTC) Received: (qmail 99571 invoked by uid 500); 6 Nov 2011 06:50:42 -0000 Delivered-To: apmail-incubator-kafka-dev-archive@incubator.apache.org Received: (qmail 99540 invoked by uid 500); 6 Nov 2011 06:50:42 -0000 Mailing-List: contact kafka-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: kafka-dev@incubator.apache.org Delivered-To: mailing list kafka-dev@incubator.apache.org Received: (qmail 99530 invoked by uid 99); 6 Nov 2011 06:50:40 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 06 Nov 2011 06:50:40 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of cryptcom@gmail.com designates 209.85.210.175 as permitted sender) Received: from [209.85.210.175] (HELO mail-iy0-f175.google.com) (209.85.210.175) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 06 Nov 2011 06:50:34 +0000 Received: by iafj26 with SMTP id j26so4381333iaf.6 for ; Sat, 05 Nov 2011 23:50:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=8Z6Lp4iTIHTQ+HNcKr7h/z/rrYnFB30DtgYcM2LD140=; b=FAlZZQuukeCwoWq2IRtPqeJuXwfcGNP9hWY2k+Le9pAAHf3XaCPYay3S0OLE8e/M9V aby3dZ1BibHav76UKSN2giadLzUR2hsVw2YSEob216qmDxsX7FaHl2cT4QSaQcL8euVk MxojMWJ+oi+1Mvfe927+mhZYaHtxN7nCaSHM4= MIME-Version: 1.0 Received: by 10.42.161.70 with SMTP id s6mr32846660icx.40.1320562213125; Sat, 05 Nov 2011 23:50:13 -0700 (PDT) Received: by 10.42.176.133 with HTTP; Sat, 5 Nov 2011 23:50:13 -0700 (PDT) In-Reply-To: References: Date: Sun, 6 Nov 2011 01:50:13 -0500 Message-ID: Subject: Re: CompressionUtilTest does not run and fails when it does From: Joe Stein To: kafka-dev@incubator.apache.org Content-Type: multipart/alternative; boundary=90e6ba2123e59dfe2704b10b595e X-Virus-Checked: Checked by ClamAV on apache.org --90e6ba2123e59dfe2704b10b595e Content-Type: text/plain; charset=ISO-8859-1 ok On Sun, Nov 6, 2011 at 1:40 AM, Neha Narkhede wrote: > Joe, > > Nice catch! This looks like a bug in the unit test. Do you want to > file a JIRA and submit a patch ? > > Thanks, > Neha > > On Sat, Nov 5, 2011 at 9:22 PM, Joe Stein wrote: > > CompressionUtilTest does not run the functions inside of it during ./sbt > > test > > > > if you change CompressionUtilTest to extend JUnitSuite then the existing > > functions run (once you adorne them with @Test) but then fail ... > > > > I suspect the TestUtils.checkEquals(messages.iterator, > > decompressedMessages.iterator) is failing in testSimpleCompressDecompress > > because all of the messages are serialized into byte arrays and the > entire > > set of messages compressed and that new compressed messages is what is > > returned as one message instead of the List[Message] and therefor are not > > interpreted within TestUtil.checkEquals to see this nuance. > > > > e.g. > > > > [error] Test Failed: testSimpleCompressDecompress > > junit.framework.AssertionFailedError: expected: > attributes = 0, crc = 3819140844, payload = java.nio.HeapByteBuffer[pos=0 > > lim=8 cap=8])> but was: 0, > > crc = 3819140844, payload = java.nio.HeapByteBuffer[pos=0 lim=8 > cap=8]),18)> > > > > and > > > > [error] Test Failed: testComplexCompressDecompress > > junit.framework.AssertionFailedError: expected:<2> but was:<3> > > > > Before opening a JIRA just wanted to check if maybe there was something > > that I was missing? > > > > /* > > Joe Stein > > http://www.linkedin.com/in/charmalloc > > Twitter: @allthingshadoop > > */ > > > -- /* Joe Stein http://www.linkedin.com/in/charmalloc Twitter: @allthingshadoop */ --90e6ba2123e59dfe2704b10b595e--