5656import static org .mockito .Mockito .verify ;
5757import static org .mockito .Mockito .when ;
5858
59- public class CoreHttpProviderTests {
59+ class CoreHttpProviderTests {
6060
6161 private CoreHttpProvider mProvider ;
6262 private Gson GSON = new GsonBuilder ().create ();
6363
6464 @ Test
65- public void testErrorResponse () throws Exception {
65+ void testErrorResponse () throws Exception {
6666 final GraphErrorCodes expectedErrorCode = GraphErrorCodes .INVALID_REQUEST ;
6767 final String expectedMessage = "Test error!" ;
6868 final GraphErrorResponse toSerialize = new GraphErrorResponse ();
@@ -85,7 +85,7 @@ public void testErrorResponse() throws Exception {
8585 }
8686
8787 @ Test
88- public void testVerboseErrorResponse () throws Exception {
88+ void testVerboseErrorResponse () throws Exception {
8989 final GraphErrorCodes expectedErrorCode = GraphErrorCodes .INVALID_REQUEST ;
9090 final String expectedMessage = "Test error!" ;
9191 final GraphErrorResponse toSerialize = new GraphErrorResponse ();
@@ -119,25 +119,25 @@ public void testVerboseErrorResponse() throws Exception {
119119 }
120120
121121 @ Test
122- public void testHasHeaderReturnsTrue () {
122+ void testHasHeaderReturnsTrue () {
123123 HeaderOption h = new HeaderOption ("name" , "value" );
124124 assertTrue (CoreHttpProvider .hasHeader (Arrays .asList (h ), "name" ));
125125 }
126126
127127 @ Test
128- public void testHasHeaderReturnsTrueWhenDifferentCase () {
128+ void testHasHeaderReturnsTrueWhenDifferentCase () {
129129 HeaderOption h = new HeaderOption ("name" , "value" );
130130 assertTrue (CoreHttpProvider .hasHeader (Arrays .asList (h ), "NAME" ));
131131 }
132132
133133 @ Test
134- public void testHasHeaderReturnsFalse () {
134+ void testHasHeaderReturnsFalse () {
135135 HeaderOption h = new HeaderOption ("name" , "value" );
136136 assertFalse (CoreHttpProvider .hasHeader (Arrays .asList (h ), "blah" ));
137137 }
138138
139139 @ Test
140- public void testStreamToStringReturnsData () {
140+ void testStreamToStringReturnsData () {
141141 String data = GSON .toJson (Maps .newHashMap (
142142 ImmutableMap .<String , String >builder ()
143143 .put ("key" , "value" )
@@ -149,14 +149,14 @@ public void testStreamToStringReturnsData() {
149149 }
150150
151151 @ Test
152- public void testStreamToStringReturnsEmpty () {
152+ void testStreamToStringReturnsEmpty () {
153153 final InputStream inputStream = new ByteArrayInputStream (new byte [0 ]);
154154
155155 String convertedData = CoreHttpProvider .streamToString (inputStream );
156156 assertEquals ("" , convertedData );
157157 }
158158 @ Test
159- public void emptyPostContentTypeIsNotReset () {
159+ void emptyPostContentTypeIsNotReset () {
160160 final String contentTypeValue = "application/json" ;
161161 final HeaderOption ctype = new HeaderOption ("Content-Type" , contentTypeValue );
162162 final ArrayList <Option > options = new ArrayList <>();
@@ -173,7 +173,7 @@ public void emptyPostContentTypeIsNotReset() {
173173 assertEquals (contentTypeValue , request .body ().contentType ().toString ());
174174 }
175175 @ Test
176- public void emptyPostContentTypeIsNotSet () {
176+ void emptyPostContentTypeIsNotSet () {
177177 final IHttpRequest absRequest = new BaseRequest <String >("https://localhost" , mock (IBaseClient .class ), Collections .emptyList (), String .class ) {{
178178 this .setHttpMethod (HttpMethod .POST );
179179 }};
@@ -210,7 +210,7 @@ private void setCoreHttpProvider(final Object toSerialize) throws IOException {
210210 mClient );
211211 }
212212 @ Test
213- public void getHttpRequestDoesntSetRetryOrRedirectOptionsOnDefaultValues () throws MalformedURLException {
213+ void getHttpRequestDoesntSetRetryOrRedirectOptionsOnDefaultValues () throws MalformedURLException {
214214 final IHttpRequest absRequest = mock (IHttpRequest .class );
215215 when (absRequest .getRequestUrl ()).thenReturn (new URL ("https://graph.microsoft.com/v1.0/me" ));
216216 when (absRequest .getHttpMethod ()).thenReturn (HttpMethod .GET );
@@ -239,7 +239,7 @@ public void getHttpRequestDoesntSetRetryOrRedirectOptionsOnDefaultValues() throw
239239 }
240240
241241 @ Test
242- public void getHttpRequestSetsRetryOrRedirectOptionsOnNonDefaultValues () throws MalformedURLException {
242+ void getHttpRequestSetsRetryOrRedirectOptionsOnNonDefaultValues () throws MalformedURLException {
243243 final IHttpRequest absRequest = mock (IHttpRequest .class );
244244 when (absRequest .getRequestUrl ()).thenReturn (new URL ("https://graph.microsoft.com/v1.0/me" ));
245245 when (absRequest .getHttpMethod ()).thenReturn (HttpMethod .GET );
@@ -295,7 +295,7 @@ public void getHttpRequestSetsRetryOrRedirectOptionsOnNonDefaultValues() throws
295295 }
296296
297297 @ Test
298- public void getHttpRequestWithTextPlainBodyDoesNotSerializeAsJson () throws IOException {
298+ void getHttpRequestWithTextPlainBodyDoesNotSerializeAsJson () throws IOException {
299299 final IHttpRequest absRequest = mock (IHttpRequest .class );
300300 when (absRequest .getRequestUrl ()).thenReturn (new URL ("https://graph.microsoft.com/v1.0/me" ));
301301 when (absRequest .getHttpMethod ()).thenReturn (HttpMethod .POST );
0 commit comments