@@ -82,7 +82,7 @@ public class FirebaseMessagingClientImplTest {
82
82
.setTopic ("test-topic" )
83
83
.build ();
84
84
private static final List <Message > MESSAGE_LIST = ImmutableList .of (EMPTY_MESSAGE , EMPTY_MESSAGE );
85
-
85
+
86
86
private static final boolean DRY_RUN_ENABLED = true ;
87
87
private static final boolean DRY_RUN_DISABLED = false ;
88
88
@@ -100,7 +100,7 @@ public void setUp() {
100
100
@ Test
101
101
public void testSend () throws Exception {
102
102
Map <Message , Map <String , Object >> testMessages = buildTestMessages ();
103
-
103
+
104
104
for (Map .Entry <Message , Map <String , Object >> entry : testMessages .entrySet ()) {
105
105
response .setContent (MOCK_RESPONSE );
106
106
String resp = client .send (entry .getKey (), DRY_RUN_DISABLED );
@@ -200,14 +200,14 @@ public void testSendErrorWithZeroContentResponse() {
200
200
@ Test
201
201
public void testSendErrorWithMalformedResponse () {
202
202
for (int code : HTTP_ERRORS ) {
203
- response .setStatusCode (code ).setContent ("not json" );
203
+ response .setStatusCode (code ).setContent ("[ not json] " );
204
204
205
205
try {
206
206
client .send (EMPTY_MESSAGE , DRY_RUN_DISABLED );
207
207
fail ("No error thrown for HTTP error" );
208
208
} catch (FirebaseMessagingException error ) {
209
209
checkExceptionFromHttpResponse (error , HTTP_2_ERROR .get (code ), null ,
210
- "Unexpected HTTP response with status: " + code + "\n not json" );
210
+ "Unexpected HTTP response with status: " + code + "\n [not json] " );
211
211
}
212
212
checkRequestHeader (interceptor .getLastRequest ());
213
213
}
0 commit comments