This commit adds code to clean the backwards compatibility cache created for each product on WC_Product_Tables_Backwards_Compatibility::get_from_product_table() whenever a product is changed and WC_Product_Data_Store_Custom_Table::clear_caches() is called. To be able to do this it was necessary to change the way the backwards compatibility class caches information. Instead of creating a cache entry for each product property, now the class will create a cache entry for each product. So now all product properties are now stored in the same cache entry.
This commit adds code to clean the backwards compatibility cache created for each product on WC_Product_Tables_Backwards_Compatibility::get_from_product_table() whenever a product is changed and WC_Product_Data_Store_Custom_Table::clear_caches() is called. To be able to do this it was necessary to change the way the backwards compatibility class caches information. Instead of creating a cache entry for each product property, now the class will create a cache entry for each product. So now all product properties are now stored in the same cache entry.
This change fixes two failing tests. Fixes #75
cc @claudiulodro