@@ -95,11 +95,14 @@ public function testCacheTagForCategoriesWithProduct()
95
95
96
96
// cache-debug header value should be a MISS when category is loaded first time
97
97
$ responseMissOnCategoryQuery = $ this ->graphQlQueryWithResponseHeaders ($ categoryQuery , $ categoryQueryVariables );
98
- print_r ("Value of Category Query " );
99
- print_r ("======= " );
100
- print_r ($ responseMissOnCategoryQuery );
101
- print_r (" end ======= " );
98
+ print_r ("Debug value Miss CacheTest testCacheIsUsedOnSecondRequest \n" );
99
+ $ json_response = json_encode ($ responseMissOnCategoryQuery , JSON_PRETTY_PRINT );
100
+ print_r ($ json_response );
101
+ print_r ("\n end \n" );
102
+ print_r ("Debug value End Miss of testCacheIsUsedOnSecondRequest \n" );
102
103
$ cacheId = $ responseMissOnCategoryQuery ['headers ' ][CacheIdCalculator::CACHE_ID_HEADER ];
104
+ print_r ("\n CacheId start \n" );
105
+ print_r ($ cacheId ."\n" );
103
106
// Verify we obtain a cache MISS the first time we search the cache using this X-Magento-Cache-Id
104
107
$ this ->assertCacheMissAndReturnResponse ($ categoryQuery , [CacheIdCalculator::CACHE_ID_HEADER => $ cacheId ]);
105
108
@@ -122,9 +125,17 @@ public function testCacheTagForCategoriesWithProduct()
122
125
);
123
126
$ this ->assertArrayHasKey (CacheIdCalculator::CACHE_ID_HEADER , $ responseMissCategoryAfterUpdate ['headers ' ]);
124
127
$ cacheId = $ responseMissCategoryAfterUpdate ['headers ' ][CacheIdCalculator::CACHE_ID_HEADER ];
128
+ print_r ("Debug value Miss CacheTest testCacheIsUsedOnSecondRequest \n" );
129
+ $ json_response = json_encode ($ responseMissOnCategoryQuery , JSON_PRETTY_PRINT );
130
+ print_r ($ json_response );
131
+ print_r ("\n end \n" );
132
+ print_r ("Debug value End Miss of testCacheIsUsedOnSecondRequest \n" );
133
+ print_r ("\n CacheId 2 start \n" );
134
+ print_r ($ cacheId ."\n" );
135
+
125
136
// Verify we obtain a cache MISS the first time we search the cache using this X-Magento-Cache-Id
126
137
$ this ->assertCacheMissAndReturnResponse ($ categoryQuery , [$ categoryQueryVariables , CacheIdCalculator::CACHE_ID_HEADER => $ cacheId ]);
127
-
138
+
128
139
// cache-debug should be a MISS for product 1 after it is updated - cache invalidation
129
140
$ responseMissFirstProductAfterUpdate = $ this ->graphQlQueryWithResponseHeaders ($ product1Query );
130
141
$ cacheId = $ responseMissFirstProductAfterUpdate ['headers ' ][CacheIdCalculator::CACHE_ID_HEADER ];
0 commit comments