Code Duplication    Length = 14-16 lines in 2 locations

tests/test_functional.py 2 locations

@@ 174-189 (lines=16) @@
171
                                headers={'Accept': 'application/json', 'Content-Type': 'application/json'})
172
        self.assertIn('ok', res.json["status"])
173
174
    @responses.activate
175
    def test_check_erfgoedgemeente_full_overlap(self):
176
        responses.add(
177
            responses.POST,
178
            'http://geozoekdienst.en',
179
            body='[{"naam": "Koksijde", "type": "gemeente", "id": "38014"}]', status=200)
180
        contour = {
181
            "coordinates": [[[[172933.6922879719, 174851.1496091811], [172930.21180502675, 174832.7836931711],
182
                              [172920.64762709616, 174848.13247794658], [172933.6922879719, 174851.1496091811]]]],
183
            "type": "MultiPolygon", "crs": {"type": "name", "properties": {"name": "urn:ogc:def:crs:EPSG::31370"}}
184
        }
185
        res = self.testapp.post('/check_in_erfgoedgemeente', params=json.dumps(contour),
186
                                headers={'Accept': 'application/json', 'Content-Type': 'application/json'})
187
        self.assertIn('error', res.json["status"])
188
        self.assertIn('Gelieve de melding in te dienen bij deze gemeente', res.json["message"])
189
190
    @responses.activate
191
    def test_check_erfgoedgemeente_partial_overlap(self):
192
        responses.add(
@@ 143-156 (lines=14) @@
140
    def test_gemeente(self):
141
        res = self.testapp.post('/gemeente', test_geom)
142
        self.assertEqual('200 OK', res.status)
143
        print(res.text)
144
145
    @responses.activate
146
    def test_gemeente(self):
147
        responses.add(responses.POST, 'http://geozoekdienst.en', body=json.dumps(get_gemeente_results))
148
        res = self.testapp.post('/gemeente', test_geom)
149
        self.assertEqual('200 OK', res.status)
150
        print(res.text)
151
152
    @responses.activate
153
    def test_provincie(self):
154
        responses.add(responses.POST, 'http://geozoekdienst.en', body=json.dumps(get_provincie_results))
155
        res = self.testapp.post('/provincie', test_geom)
156
        self.assertEqual('200 OK', res.status)
157
        print(res.text)
158
159
    @responses.activate