Pig
  1. Pig
  2. PIG-124

only run one test (aant runtest -Dtest=TestMapReduce) not the complete test suite

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.1.0
    • Component/s: None
    • Labels:
      None
    • Patch Info:
      Patch Available

      Description

      +1 to what Xu is saying.

      1. RunIndividualTestCase.patch
        2 kB
        Xu Zhang
      2. PIG-124_v_1.patch
        4 kB
        Stefan Groschupf

        Activity

        Hide
        Stefan Groschupf added a comment -

        another build.xml improvement again r631029.

        Show
        Stefan Groschupf added a comment - another build.xml improvement again r631029.
        Hide
        Pi Song added a comment -

        +1 I've been looking forward to this.

        Show
        Pi Song added a comment - +1 I've been looking forward to this.
        Hide
        Xu Zhang added a comment - - edited

        As described in the last bullet of section "Making Changes" in the HowToContribute doc ( http://wiki.apache.org/pig/HowToContribute ), Pig does (or is supposed to ) support the following command for running an individual testcase class,

        ant test -Dtestcase=<ClassName>  (For example ant test -Dtestcase=TestPigFile)
        

        although it was not working last I checked. Personally, I would prefer it this way since this command conforms to what Hadoop uses to achieve the same purpose. To make work, what we need to do is just port the same functionality from Hadoop's build.xml to Pig's build.xml.

        So if there is no objections, either Stefan (since Stefan has been doing a great job on this already) or myself can start making the above command work as expected.

        Show
        Xu Zhang added a comment - - edited As described in the last bullet of section "Making Changes" in the HowToContribute doc ( http://wiki.apache.org/pig/HowToContribute ), Pig does (or is supposed to ) support the following command for running an individual testcase class, ant test -Dtestcase=<ClassName> (For example ant test -Dtestcase=TestPigFile) although it was not working last I checked. Personally, I would prefer it this way since this command conforms to what Hadoop uses to achieve the same purpose. To make work, what we need to do is just port the same functionality from Hadoop's build.xml to Pig's build.xml. So if there is no objections, either Stefan (since Stefan has been doing a great job on this already) or myself can start making the above command work as expected.
        Hide
        Xu Zhang added a comment -

        Attach a patch that makes build.xml able to run the individual test case class.

        Show
        Xu Zhang added a comment - Attach a patch that makes build.xml able to run the individual test case class.
        Hide
        Stefan Groschupf added a comment -

        +1
        Xu: cool - even better than my solution. Thanks!
        Lets get it in soon - waiting 12 minutes to run a test every time is painful.

        Show
        Stefan Groschupf added a comment - +1 Xu: cool - even better than my solution. Thanks! Lets get it in soon - waiting 12 minutes to run a test every time is painful.
        Hide
        Xu Zhang added a comment -

        Credit goes to whoever did the similar thing for Hadoop.

        Show
        Xu Zhang added a comment - Credit goes to whoever did the similar thing for Hadoop .
        Hide
        Arun C Murthy added a comment -

        Xu, can you also add the 'test.output' flag to pig's build.xml, similar to hadoop? This ensures that we get output on the screen while the test case is running... which is usually very useful for debugging. Thanks!

        Show
        Arun C Murthy added a comment - Xu, can you also add the 'test.output' flag to pig's build.xml, similar to hadoop? This ensures that we get output on the screen while the test case is running... which is usually very useful for debugging. Thanks!
        Hide
        Xu Zhang added a comment -

        Sure. I am working on it now.

        Show
        Xu Zhang added a comment - Sure. I am working on it now.
        Hide
        Xu Zhang added a comment -

        Here you go, Arun. To use it, on the command line specify the option "-Dtest.ouput=yes". I will update the related documents for this option accordingly.

        Show
        Xu Zhang added a comment - Here you go, Arun. To use it, on the command line specify the option "-Dtest.ouput=yes". I will update the related documents for this option accordingly.
        Hide
        Olga Natkovich added a comment -

        Patch committed. Xu, thanks for contributing

        Show
        Olga Natkovich added a comment - Patch committed. Xu, thanks for contributing

          People

          • Assignee:
            Stefan Groschupf
            Reporter:
            Stefan Groschupf
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development