public void GetSet_when_l1_misses_then_l2_called() { // Arrange var l1 = false; var l2 = false; var level1 = new InspectableCache((key) => { l1 = true; }, cacheMiss: true); var level2 = new InspectableCache((key) => { l2 = true; }); var sut = new CompositeCache(level1, level2); // Act var result = sut.GetSet("a", () => "", TimeSpan.Zero); // Assert Assert.True(l1); Assert.True(l2); }