old_contents: from disco.test import DiscoJobTestFixture, DiscoTestCase
  
  from disco.error import JobError
  
  class RawTestCase(DiscoJobTestFixture, DiscoTestCase):
      @property
      def input(self):
          return ['raw://eeny', 'raw://meeny', 'raw://miny', 'raw://moe']
  
      @staticmethod
      def map(e, params):
          return [('', e + ':map')]
  
      def runTest(self):
          answers, results = self.answers, list(self.results)
          self.assertEquals(len(answers), len(results))
          for key, result in results:
              self.assert_(result in answers)
  
      @property
      def answers(self):
          return dict((input.strip('raw://') + ':map', True)
                      for input in self.input)
  
  
new_contents: from disco.test import TestCase, TestJob
  
  class RawJob(TestJob):
      @staticmethod
      def map(e, params):
          yield 'raw://%s' % e, ''
  
  class RawTestCase(TestCase):
      def runTest(self):
          input = ['raw://eeny', 'raw://meeny', 'raw://miny', 'raw://moe']
          self.job = RawJob().run(input=input)
          self.assertEqual(sorted(self.results(self.job)),
                           sorted((i, '') for i in input))
  
  
subject: convert test_raw