@@ -104,11 +104,17 @@ public void isCacheableContent() {
104104 assertFalse (cache .isCacheableContent (response ));
105105 }
106106
107+ /**
108+ * @throws Exception if the test fails
109+ */
107110 @ Test
108111 public void contentWithNoHeadersIsNotCached () {
109112 assertFalse (Cache .isWithinCacheWindow (new WebResponseMock (null , null ), now_ , now_ ));
110113 }
111114
115+ /**
116+ * @throws Exception if the test fails
117+ */
112118 @ Test
113119 public void contentWithExpiryDateIsCached () {
114120 final Map <String , String > headers = new HashMap <>();
@@ -117,6 +123,9 @@ public void contentWithExpiryDateIsCached() {
117123 assertTrue (Cache .isWithinCacheWindow (new WebResponseMock (null , headers ), now_ , now_ ));
118124 }
119125
126+ /**
127+ * @throws Exception if the test fails
128+ */
120129 @ Test
121130 public void contentWithExpiryDateInFutureButShortMaxAgeIsNotInCacheWindow () {
122131 final Map <String , String > headers = new HashMap <>();
@@ -127,6 +136,9 @@ public void contentWithExpiryDateInFutureButShortMaxAgeIsNotInCacheWindow() {
127136 assertFalse (Cache .isWithinCacheWindow (new WebResponseMock (null , headers ), now_ + ONE_MINUTE , now_ ));
128137 }
129138
139+ /**
140+ * @throws Exception if the test fails
141+ */
130142 @ Test
131143 public void contentWithExpiryDateInFutureButShortSMaxAgeIsNotInCacheWindow () {
132144 final Map <String , String > headers = new HashMap <>();
@@ -137,6 +149,9 @@ public void contentWithExpiryDateInFutureButShortSMaxAgeIsNotInCacheWindow() {
137149 assertFalse (Cache .isWithinCacheWindow (new WebResponseMock (null , headers ), now_ + ONE_MINUTE , now_ ));
138150 }
139151
152+ /**
153+ * @throws Exception if the test fails
154+ */
140155 @ Test
141156 public void contentWithBothMaxAgeAndSMaxUsesSMaxAsPriority () {
142157 final Map <String , String > headers = new HashMap <>();
@@ -145,6 +160,9 @@ public void contentWithBothMaxAgeAndSMaxUsesSMaxAsPriority() {
145160 assertFalse (Cache .isWithinCacheWindow (new WebResponseMock (null , headers ), now_ + ONE_MINUTE , now_ ));
146161 }
147162
163+ /**
164+ * @throws Exception if the test fails
165+ */
148166 @ Test
149167 public void contentWithMaxAgeInFutureWillBeCached () {
150168 final Map <String , String > headers = new HashMap <>();
@@ -158,6 +176,9 @@ public void contentWithMaxAgeInFutureWillBeCached() {
158176 assertTrue (Cache .isWithinCacheWindow (new WebResponseMock (null , headers ), now_ + ONE_MINUTE , now_ ));
159177 }
160178
179+ /**
180+ * @throws Exception if the test fails
181+ */
161182 @ Test
162183 public void contentWithLongLastModifiedTimeComparedToNowIsCachedOnDownload () {
163184 final Map <String , String > headers = new HashMap <>();
@@ -166,6 +187,9 @@ public void contentWithLongLastModifiedTimeComparedToNowIsCachedOnDownload() {
166187 assertTrue (Cache .isWithinCacheWindow (new WebResponseMock (null , headers ), now_ , now_ ));
167188 }
168189
190+ /**
191+ * @throws Exception if the test fails
192+ */
169193 @ Test
170194 public void contentWithLastModifiedTimeIsCachedAfterAFewPercentOfCreationAge () {
171195 final Map <String , String > headers = new HashMap <>();
@@ -174,6 +198,9 @@ public void contentWithLastModifiedTimeIsCachedAfterAFewPercentOfCreationAge() {
174198 assertTrue (Cache .isWithinCacheWindow (new WebResponseMock (null , headers ), now_ + ONE_HOUR , now_ ));
175199 }
176200
201+ /**
202+ * @throws Exception if the test fails
203+ */
177204 @ Test
178205 public void contentWithLastModifiedTimeIsNotCachedAfterALongerPeriod () {
179206 final Map <String , String > headers = new HashMap <>();
0 commit comments