chore(): Allow to register modules through array (#9522)

This commit is contained in:
Adrien de Peretti
2024-10-11 15:17:00 +02:00
committed by GitHub
parent 9c73503084
commit 1d8939df3a
35 changed files with 954 additions and 349 deletions
@@ -692,7 +692,7 @@ moduleIntegrationTestRunner<IProductModuleService>({
[
expect.objectContaining({
data: { id: productCategoryOne.id },
name: "Product.product-category.deleted",
name: "product.product-category.deleted",
metadata: {
action: CommonEvents.DELETED,
object: "product_category",
@@ -281,7 +281,7 @@ moduleIntegrationTestRunner<IProductModuleService>({
expect(eventBusSpy).toHaveBeenCalledWith(
[
{
name: "Product.product-collection.deleted",
name: "product.product-collection.deleted",
data: { id: collectionId },
metadata: {
action: CommonEvents.DELETED,
@@ -72,7 +72,7 @@ moduleIntegrationTestRunner<Service>({
linkable: "product_id",
entity: "Product",
primaryKey: "id",
serviceName: "Product",
serviceName: "product",
field: "product",
},
},
@@ -81,7 +81,7 @@ moduleIntegrationTestRunner<Service>({
linkable: "product_variant_id",
entity: "ProductVariant",
primaryKey: "id",
serviceName: "Product",
serviceName: "product",
field: "productVariant",
},
variant_id: {
@@ -89,7 +89,7 @@ moduleIntegrationTestRunner<Service>({
entity: "ProductVariant",
linkable: "variant_id",
primaryKey: "variant_id",
serviceName: "Product",
serviceName: "product",
},
},
productOption: {
@@ -97,7 +97,7 @@ moduleIntegrationTestRunner<Service>({
linkable: "product_option_id",
entity: "ProductOption",
primaryKey: "id",
serviceName: "Product",
serviceName: "product",
field: "productOption",
},
},
@@ -106,7 +106,7 @@ moduleIntegrationTestRunner<Service>({
linkable: "product_type_id",
entity: "ProductType",
primaryKey: "id",
serviceName: "Product",
serviceName: "product",
field: "productType",
},
},
@@ -115,7 +115,7 @@ moduleIntegrationTestRunner<Service>({
linkable: "product_image_id",
entity: "ProductImage",
primaryKey: "id",
serviceName: "Product",
serviceName: "product",
field: "productImage",
},
},
@@ -124,7 +124,7 @@ moduleIntegrationTestRunner<Service>({
linkable: "product_tag_id",
entity: "ProductTag",
primaryKey: "id",
serviceName: "Product",
serviceName: "product",
field: "productTag",
},
},
@@ -133,7 +133,7 @@ moduleIntegrationTestRunner<Service>({
linkable: "product_collection_id",
entity: "ProductCollection",
primaryKey: "id",
serviceName: "Product",
serviceName: "product",
field: "productCollection",
},
},
@@ -142,7 +142,7 @@ moduleIntegrationTestRunner<Service>({
linkable: "product_category_id",
entity: "ProductCategory",
primaryKey: "id",
serviceName: "Product",
serviceName: "product",
field: "productCategory",
},
},