Beispiel #1
0
 def test_context_other_section(self):
     self.client.regulation.return_value = {"label": ['222', '22']}
     self.assertEqual(
         analyses.Analyses('222-22', 'vvv').context(self.client, None),
         {'version': 'vvv',
          'human_label_id': u'§ 222.22',
          'analyses': []})
Beispiel #2
0
 def test_context_paragraph(self):
     self.client.regulation.return_value = {"label": ['111', '22', 'a']}
     self.assertEqual(
         analyses.Analyses('111-22-a', 'vvv').context(self.client, None),
         {'version': 'vvv',
          'human_label_id': u'§ 111.22(a)',
          'analyses': [
              {'doc_number': '2009-22', 'label_id': '111-22-a',
               'text': u'§ 22(a)'}
          ]})
Beispiel #3
0
 def test_context_interp_child(self):
     self.client.regulation.return_value = {
         "label": ['111', '22', 'Interp', '2']}
     self.assertEqual(
         analyses.Analyses('111-22-Interp-2', 'vvv').context(self.client,
                                                             None),
         {'version': 'vvv',
          'human_label_id': 'Comment for 111.22-2',
          'analyses': [
              {'doc_number': '2007-22', 'label_id': '111-22-Interp-2',
               'text': 'Comment for 111.22-2'}
          ]})