Hadoop HDFS
  1. Hadoop HDFS
  2. HDFS-2276

src/test/unit tests not being run in mavenized HDFS

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Critical Critical
    • Resolution: Unresolved
    • Affects Version/s: 2.0.0-alpha
    • Fix Version/s: None
    • Component/s: build, test
    • Labels:
      None
    • Target Version/s:

      Description

      There are about 5 tests in src/test/unit that are no longer being run.

      1. hdfs-2276.txt
        109 kB
        Todd Lipcon

        Issue Links

          Activity

          Hide
          Todd Lipcon added a comment -

          I'd like to do the following:

          • add 3 empty interfaces to the "common" project:
            • SmallTest – for true "unit" tests that don't hit disk or network and don't sleep
            • MediumTest – for functional tests that check a subsystem and might use local disk or loopback sockets, but should still run in under a few seconds. For example, HDFS tests that start a NN but no DNs.
            • LargeTest – for system-wide functional tests - for example things like TestHDFSCLI that take several minutes but cover a large swath of the system.

          These would be used with the JUnit 4.8 @Category annotation, eg @Category(LargeTest.class).

          These are modeled after the categories in this excellent article: http://googletesting.blogspot.com/2009/07/software-testing-categorization.html

          • mark the existing tests in src/test/unit as @Category(SmallTest.class), and move them into src/test/java.

          We can use these annotations to have different test targets for the different size tests using the functionality in http://jira.codehaus.org/browse/SUREFIRE-329 once that's released

          Show
          Todd Lipcon added a comment - I'd like to do the following: add 3 empty interfaces to the "common" project: SmallTest – for true "unit" tests that don't hit disk or network and don't sleep MediumTest – for functional tests that check a subsystem and might use local disk or loopback sockets, but should still run in under a few seconds. For example, HDFS tests that start a NN but no DNs. LargeTest – for system-wide functional tests - for example things like TestHDFSCLI that take several minutes but cover a large swath of the system. These would be used with the JUnit 4.8 @Category annotation, eg @Category(LargeTest.class). These are modeled after the categories in this excellent article: http://googletesting.blogspot.com/2009/07/software-testing-categorization.html mark the existing tests in src/test/unit as @Category(SmallTest.class), and move them into src/test/java. We can use these annotations to have different test targets for the different size tests using the functionality in http://jira.codehaus.org/browse/SUREFIRE-329 once that's released
          Hide
          Tom White added a comment -

          +1

          Show
          Tom White added a comment - +1
          Hide
          Jakob Homan added a comment -

          We can also use the timeout rule introduced in HADOOP-6987 for small or medium tests that violate their runtime contract. this was introduced but fell off the radar for being added to tests.

          Show
          Jakob Homan added a comment - We can also use the timeout rule introduced in HADOOP-6987 for small or medium tests that violate their runtime contract. this was introduced but fell off the radar for being added to tests.
          Hide
          Todd Lipcon added a comment -

          Here's a patch to add the interfaces and categorizations.

          Show
          Todd Lipcon added a comment - Here's a patch to add the interfaces and categorizations.

            People

            • Assignee:
              Todd Lipcon
              Reporter:
              Todd Lipcon
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:

                Development