FAQ
Hi,

I've imported the hadoop common trunk in eclipse (.classpath and
.project created via ant eclipse).

ant test build fine (0 failures).

When I run the junit tests from eclipse (right-click on test folder,
"Run as test"), there are many failures...

Is there some env (-D...) to give when running from eclipse.
I could hack the ant scripts, but someone here may know the answer :)

Many tks for your help,
- Eric

Search Discussions

  • Harsh J at Jun 13, 2011 at 9:58 am
    Eric,

    Is the problem reported as something like "webapps not found on
    CLASSPATH"? I see this on mapreduce and hdfs projects at times, but
    common tests usually run fine out of the box for me.

    If it is indeed that, this conversation may help solve/provide an
    answer: http://search-hadoop.com/m/gLWelrO8Mc

    On Mon, Jun 13, 2011 at 12:49 PM, Eric Charles
    wrote:
    Hi,

    I've imported the hadoop common trunk in eclipse (.classpath and .project
    created via ant eclipse).

    ant test build fine (0 failures).

    When I run the junit tests from eclipse (right-click on test folder, "Run as
    test"), there are many failures...

    Is there some env (-D...) to give when running from eclipse.
    I could hack the ant scripts, but someone here may know the answer :)

    Many tks for your help,
    - Eric


    --
    Harsh J
  • Eric Charles at Jun 20, 2011 at 2:58 pm
    Hi Harsh,

    Tks for your quick reply, and sorry to be so late.

    http://search-hadoop.com/m/gLWelrO8Mc helped me to find the Launch
    configuration for hadoop-hdfs and hadoop-mapreduce, but there are no
    such Launch config for hadoop-common.

    Never mind, I just replaced :hdfs with :common and got [1].

    My test success % has made an impressive jump, but I still have a few
    failures for example:
    junit.framework.AssertionFailedError: -expunge failed expected:<0> but
    was:(TestTrash.java:328)
    at org.apache.hadoop.fs.TestTrash.trashShell(TestTrash.java:102)
    at org.apache.hadoop.fs.TestTrash.testTrash(TestTrash.java:447)


    About the needed environment variables to run the tests:

    1.- Should the Launch configs be documented on
    http://wiki.apache.org/hadoop/EclipseEnvironment ?

    2.- should Launch config be created for hadoop-common project ?

    2.- The tests depend heavily on env variables. I wonder how to handle
    this with the upcoming maven structure
    (https://issues.apache.org/jira/browse/HADOOP-6671). Should we forsee
    during the test setUp() some default values, a bit like if we would
    generalize https://issues.apache.org/jira/browse/HADOOP-5916
    (Standardize fall-back value of test.build.data for testing directories)
    to all needed env.

    Maybe this is already a know topic?
    Tks.

    [1] -Xms256m -Xmx512m
    -Dtest.build.data=${workspace_loc:common}/build/test
    -Dtest.cache.data=${workspace_loc:common}/build/test/cache
    -Dtest.debug.data=${workspace_loc:common}/build/test/debug
    -Dhadoop.log.dir=${workspace_loc:common}/build/test/log
    -Dtest.src.dir=${workspace_loc:common}/build/test/src
    -Dtest.build.extraconf=${workspace_loc:common}/build/test/extraconf
    -Dhadoop.policy.file=hadoop-policy.xml
    On 13/06/11 11:57, Harsh J wrote:
    Eric,

    Is the problem reported as something like "webapps not found on
    CLASSPATH"? I see this on mapreduce and hdfs projects at times, but
    common tests usually run fine out of the box for me.

    If it is indeed that, this conversation may help solve/provide an
    answer: http://search-hadoop.com/m/gLWelrO8Mc

    On Mon, Jun 13, 2011 at 12:49 PM, Eric Charles
    wrote:
    Hi,

    I've imported the hadoop common trunk in eclipse (.classpath and .project
    created via ant eclipse).

    ant test build fine (0 failures).

    When I run the junit tests from eclipse (right-click on test folder, "Run as
    test"), there are many failures...

    Is there some env (-D...) to give when running from eclipse.
    I could hack the ant scripts, but someone here may know the answer :)

    Many tks for your help,
    - Eric
    --
    Eric

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupcommon-user @
categorieshadoop
postedJun 13, '11 at 7:20a
activeJun 20, '11 at 2:58p
posts3
users2
websitehadoop.apache.org...
irc#hadoop

2 users in discussion

Eric Charles: 2 posts Harsh J: 1 post

People

Translate

site design / logo © 2022 Grokbase