-
Notifications
You must be signed in to change notification settings - Fork 25
/
ConsumeTextTest.cs
37 lines (33 loc) · 1.21 KB
/
ConsumeTextTest.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
using Xunit;
namespace RingCentral.Tests;
[Collection("Sequential")]
public class ConsumeTextTest
{
[Fact]
public async void UpdateGlipPostText()
{
var rc = await ReusableRestClient.GetInstance();
var currentExtension = await rc.Restapi().Account().Extension().Get();
// todo: https://jira.ringcentral.com/browse/PLD-1880
// var foundIt = false;
// foreach (var group in (await rc.TeamMessaging().V1().Chats().List()).records)
// {
// foreach (var post in (await rc.TeamMessaging().V1().Chats(group.id).Posts().List()).records)
// if (post.creatorId == currentExtension.id.ToString() && !string.IsNullOrEmpty(post.text))
// {
// foundIt = true;
//
// var newText = Guid.NewGuid().ToString();
// var r = await rc.TeamMessaging().V1().Chats(group.id).Posts(post.id)
// .Patch(new TMUpdatePostRequest {text = newText});
// Assert.Equal(r.text, newText);
//
// break;
// }
//
// if (foundIt) break;
// }
//
// Assert.True(foundIt);
}
}