def test_informatieobjecttype_filter(self):
        zaak_url = "http://www.example.com/zrc/api/v1/zaken/1"

        ObjectInformatieObjectFactory.create_batch(
            2,
            is_zaak=True,
            object=zaak_url,
            informatieobject__latest_version__informatieobjecttype=
            INFORMATIEOBJECTTYPE,
        )
        ObjectInformatieObjectFactory.create(
            is_zaak=True,
            object="http://www.example.com/zrc/api/v1/zaken/2",
            informatieobject__latest_version__informatieobjecttype=
            INFORMATIEOBJECTTYPE,
        )

        url = get_operation_url("objectinformatieobject_list")

        response = self.client.get(url, {"object": zaak_url})

        self.assertEqual(response.status_code, status.HTTP_200_OK,
                         response.json())

        response_data = response.json()
        self.assertEqual(len(response_data), 2)

        for zio in response_data:
            self.assertEqual(zio["object"], zaak_url)
    def test_informatieobjecttype_filter(self):
        zaak_url = 'http://www.example.com/zrc/api/v1/zaken/1'

        ObjectInformatieObjectFactory.create_batch(2, is_zaak=True, object=zaak_url)
        ObjectInformatieObjectFactory.create(is_zaak=True, object='http://www.example.com/zrc/api/v1/zaken/2')

        url = get_operation_url('objectinformatieobject_list')

        response = self.client.get(url, {'object': zaak_url})

        self.assertEqual(response.status_code, status.HTTP_200_OK, response.json())

        response_data = response.json()
        self.assertEqual(len(response_data), 2)

        for zio in response_data:
            self.assertEqual(zio['object'], zaak_url)