This repository was archived by the owner on Sep 4, 2020. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +14
-1
lines changed
graphsdk/src/androidTest/java/com/microsoft/graph/functional Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Original file line number Diff line number Diff line change 77import com .microsoft .graph .extensions .*;
88
99import org .junit .Assert ;
10+ import org .junit .Test ;
1011
1112import javax .xml .datatype .DatatypeFactory ;
1213import javax .xml .datatype .Duration ;
@@ -39,12 +40,24 @@ public void testSendMail() {
3940 testBase .graphClient .getMe ().getSendMail (message , true ).buildRequest ().post ();
4041 }
4142
43+ @ Test
4244 public void testGetFindMeetingTimes () {
4345 TestBase testBase = new TestBase ();
46+
47+ // Get the first user in the tenant
48+ User me = testBase .graphClient .getMe ().buildRequest ().get ();
49+ IUserCollectionPage users = testBase .graphClient .getUsers ().buildRequest ().get ();
50+ User tenantUser = users .getCurrentPage ().get (0 );
51+
52+ //Ensure that the user grabbed is not the logged-in user
53+ if (tenantUser .mail .equals (me .mail )) {
54+ tenantUser = users .getCurrentPage ().get (1 );
55+ }
56+
4457 List <AttendeeBase > attendees = new ArrayList <>();
4558 AttendeeBase attendeeBase = new AttendeeBase ();
4659 EmailAddress email = new EmailAddress ();
47- email .
address =
"[email protected] " ;
60+ email .address = tenantUser . mail ;
4861 attendeeBase .emailAddress = email ;
4962 attendees .add (attendeeBase );
5063 try {
You can’t perform that action at this time.
0 commit comments