Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Add benchmark

Marcin Gębala1863ff6f4007
diff --git a/saleor/graphql/product/tests/benchmark/test_product.py b/saleor/graphql/product/tests/benchmark/test_product.py
index c11429cac8..c6cb17313a 100644
--- a/saleor/graphql/product/tests/benchmark/test_product.py
+++ b/saleor/graphql/product/tests/benchmark/test_product.py
@@ -178,3 +178,32 @@ def test_retrieve_product_attributes(product_list, api_client, count_queries):
variables = {}
get_graphql_content(api_client.post_graphql(query, variables))
+
+
[email protected]_queries(autouse=False)
+def test_retrive_products_with_product_types_and_attributes(
+ product_list, api_client, count_queries
+):
+ query = """
+ {
+ products(first: 10) {
+ edges {
+ node {
+ id
+ productType {
+ name
+ productAttributes {
+ name
+ }
+ variantAttributes {
+ name
+ }
+ }
+ }
+ }
+ }
+ }
+ """
+ variables = {}
+ get_graphql_content(api_client.post_graphql(query, variables))