Issue #2795579 by martin107, klausi, dawehner: Adapt assertCacheContexts to not rely on the return value of assertIdentical