Skip to content

Commit eb3b691

Browse files
committed
Merge branch 'dev' into feature/v3
2 parents b55c815 + 428a13a commit eb3b691

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

src/test/java/com/microsoft/graph/functional/UserTests.java

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import static org.junit.jupiter.api.Assertions.assertNotEquals;
44
import static org.junit.jupiter.api.Assertions.assertEquals;
55
import static org.junit.jupiter.api.Assertions.assertNotNull;
6+
import static org.junit.jupiter.api.Assertions.assertNull;
67

78
import java.io.File;
89
import java.io.FileInputStream;
@@ -206,8 +207,8 @@ public void run() {
206207
}
207208
}
208209

209-
@Test
210-
public void emptyPostContentType() {
210+
@Test
211+
public void emptyPostContentTypeIsNotReset() {
211212
final String contentTypeValue = "application/json";
212213
final HeaderOption ctype = new HeaderOption("Content-Type", contentTypeValue);
213214
final ArrayList<Option> options = new ArrayList<>();
@@ -219,6 +220,15 @@ public void emptyPostContentType() {
219220
.getHttpRequest();
220221
assertEquals(contentTypeValue, request.body().contentType().toString());
221222
}
223+
@Test
224+
public void emptyPostContentTypeIsNotSet() {
225+
final Request request = graphServiceClient.me()
226+
.revokeSignInSessions()
227+
.buildRequest()
228+
.withHttpMethod(HttpMethod.POST)
229+
.getHttpRequest();
230+
assertNull(request.body().contentType());
231+
}
222232
@Test
223233
public void castTest() {
224234
final GroupCollectionPage groups = graphServiceClient.groups().buildRequest().top(1).get();

0 commit comments

Comments
 (0)