Uploaded image for project: 'MRUnit'
  1. MRUnit
  2. MRUNIT-167

context passed to an OuputFormatter is ignored by the framework

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 1.0.0
    • Fix Version/s: 1.0.0
    • Labels:
      None

      Description

      The following method creates a context that it passes to the output formatter under test, however it ignores the results:

      org.apache.hadoop.mrunit.internal.mapreduce.MockMapreduceOutputFormat.collect(K, V)

      specifically if the output formatter increments counters the counters are not available to the test code. (DummyReporter just creates a new Counter() each time) In my case I'm incrementing counters in my output formatter but these counters are not available when I check in my junit test method at the end of the test run.

      I'm using the latest 1.0.0 snapshot with hadoop2 classifier.

        Attachments

        1. MRUNIT-167-1.patch
          16 kB
          Brock Noland
        2. MRUNIT-167-0.patch
          15 kB
          Brock Noland

          Activity

            People

            • Assignee:
              brocknoland Brock Noland
              Reporter:
              phunt Patrick D. Hunt
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: