(PC-31951)[API] fix: Event products can only be of type SEANCE_CINE #4759
2520 tests run, 2506 passed, 1 skipped, 13 failed.
Annotations
Check failure on line 253 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_unlimited_stock
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:255: in test_get_offer_with_unlimited_stock
product = offers_factories.ProductFactory(thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 267 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_thing_offer
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:269: in test_get_thing_offer
product = offers_factories.ProductFactory(thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 626 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_product_mediation_and_thumb
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:628: in test_get_offer_with_product_mediation_and_thumb
product = offers_factories.ProductFactory(thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 647 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_two_product_mediation
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:649: in test_get_offer_with_two_product_mediation
product = offers_factories.ProductFactory(thumbCount=0, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 671 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_thumb_only
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:673: in test_get_offer_with_thumb_only
product = offers_factories.ProductFactory(id=111, thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 689 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_mediation_and_product_mediation
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:691: in test_get_offer_with_mediation_and_product_mediation
product = offers_factories.ProductFactory(thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 930 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_unlimited_stock
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:932: in test_get_offer_with_unlimited_stock
product = offers_factories.ProductFactory(thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 942 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_thing_offer
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:944: in test_get_thing_offer
product = offers_factories.ProductFactory(thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 1454 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_product_mediation_and_thumb
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:1456: in test_get_offer_with_product_mediation_and_thumb
product = offers_factories.ProductFactory(thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 1476 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_two_product_mediation
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:1478: in test_get_offer_with_two_product_mediation
product = offers_factories.ProductFactory(thumbCount=0, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 1505 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_thumb_only
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:1507: in test_get_offer_with_thumb_only
product = offers_factories.ProductFactory(id=111, thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 1524 in tests/routes/native/v1/offers_test.py
github-actions / Pytest Report
tests/routes/native/v1/offers_test.py.test_get_offer_with_mediation_and_product_mediation
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/native/v1/offers_test.py:1526: in test_get_offer_with_mediation_and_product_mediation
product = offers_factories.ProductFactory(thumbCount=1, subcategoryId=subcategories.CARTE_MUSEE.id)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Check failure on line 23 in tests/routes/public/individual_offers/v1/get_eans_availability_test.py
github-actions / Pytest Report
tests/routes/public/individual_offers/v1/get_eans_availability_test.py.test_should_return_eans_ordered_by_availability
ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].
Raw output
tests/routes/public/individual_offers/v1/get_eans_availability_test.py:36: in test_should_return_eans_ordered_by_availability
offers_factories.ProductFactory(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:43: in __call__
return cls.create(**kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:539: in create
return cls._generate(enums.CREATE_STRATEGY, kwargs)
/home/pcapi/.local/lib/python3.11/site-packages/factory/alchemy.py:60: in _generate
return super()._generate(strategy, params)
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:468: in _generate
return step.build()
/home/pcapi/.local/lib/python3.11/site-packages/factory/builder.py:274: in build
instance = self.factory_meta.instantiate(
/home/pcapi/.local/lib/python3.11/site-packages/factory/base.py:320: in instantiate
return self.factory._create(model, *args, **kwargs)
src/pcapi/core/offers/factories.py:53: in _create
raise ValueError(f"Events products subcategory can only be one of {cls.AVAILABLE_SUBCATEGORIES}.")
E ValueError: Events products subcategory can only be one of ['SEANCE_CINE', 'LIVRE_PAPIER', 'SUPPORT_PHYSIQUE_MUSIQUE_CD', 'SUPPORT_PHYSIQUE_MUSIQUE_VINYLE'].