@@ -135,10 +135,10 @@ void hasValueWithNoStringMatch() {
135
135
136
136
@ Test
137
137
void hasValueWithNonPresentHeader () {
138
- HttpHeaders map = new HttpHeaders ();
139
- map .add ("test-header" , "a" );
138
+ HttpHeaders headers = new HttpHeaders ();
139
+ headers .add ("test-header" , "a" );
140
140
assertThatExceptionOfType (AssertionError .class )
141
- .isThrownBy (() -> assertThat (map ).hasValue ("wrong-name" , "a" ))
141
+ .isThrownBy (() -> assertThat (headers ).hasValue ("wrong-name" , "a" ))
142
142
.withMessageContainingAll ("HTTP headers" , "test-header" , "wrong-name" );
143
143
}
144
144
@@ -151,19 +151,19 @@ void hasValueWithLongMatch() {
151
151
152
152
@ Test
153
153
void hasValueWithLongMatchOnSecondaryValue () {
154
- HttpHeaders map = new HttpHeaders ();
155
- map .addAll ("header" , List .of ("123" , "456" , "789" ));
154
+ HttpHeaders headers = new HttpHeaders ();
155
+ headers .addAll ("header" , List .of ("123" , "456" , "789" ));
156
156
assertThatExceptionOfType (AssertionError .class )
157
- .isThrownBy (() -> assertThat (map ).hasValue ("header" , 456 ))
157
+ .isThrownBy (() -> assertThat (headers ).hasValue ("header" , 456 ))
158
158
.withMessageContainingAll ("check primary long value for HTTP header 'header'" , "123" , "456" );
159
159
}
160
160
161
161
@ Test
162
162
void hasValueWithNoLongMatch () {
163
- HttpHeaders map = new HttpHeaders ();
164
- map .addAll ("header" , List .of ("123" , "456" , "789" ));
163
+ HttpHeaders headers = new HttpHeaders ();
164
+ headers .addAll ("header" , List .of ("123" , "456" , "789" ));
165
165
assertThatExceptionOfType (AssertionError .class )
166
- .isThrownBy (() -> assertThat (map ).hasValue ("wrong-name" , 456 ))
166
+ .isThrownBy (() -> assertThat (headers ).hasValue ("wrong-name" , 456 ))
167
167
.withMessageContainingAll ("HTTP headers" , "header" , "wrong-name" );
168
168
}
169
169
@@ -178,20 +178,20 @@ void hasValueWithInstantMatch() {
178
178
@ Test
179
179
void hasValueWithNoInstantMatch () {
180
180
Instant instant = Instant .now ();
181
- HttpHeaders map = new HttpHeaders ();
182
- map .setInstant ("header" , instant );
181
+ HttpHeaders headers = new HttpHeaders ();
182
+ headers .setInstant ("header" , instant );
183
183
assertThatExceptionOfType (AssertionError .class )
184
- .isThrownBy (() -> assertThat (map ).hasValue ("wrong-name" , instant .minusSeconds (30 )))
184
+ .isThrownBy (() -> assertThat (headers ).hasValue ("wrong-name" , instant .minusSeconds (30 )))
185
185
.withMessageContainingAll ("HTTP headers" , "header" , "wrong-name" );
186
186
}
187
187
188
188
@ Test
189
189
void hasValueWithNoInstantMatchOneSecOfDifference () {
190
190
Instant instant = Instant .now ();
191
- HttpHeaders map = new HttpHeaders ();
192
- map .setInstant ("header" , instant );
191
+ HttpHeaders headers = new HttpHeaders ();
192
+ headers .setInstant ("header" , instant );
193
193
assertThatExceptionOfType (AssertionError .class )
194
- .isThrownBy (() -> assertThat (map ).hasValue ("wrong-name" , instant .minusSeconds (1 )))
194
+ .isThrownBy (() -> assertThat (headers ).hasValue ("wrong-name" , instant .minusSeconds (1 )))
195
195
.withMessageContainingAll ("HTTP headers" , "header" , "wrong-name" );
196
196
}
197
197
0 commit comments