I have retrieved a FeedElement by it's postId. I now want to test that the feed.body is a certain value. FeedElement.Body is of type FeedBody. This is the documentation for FeedBody which as you can see doesn't say much. What is the best way to turn a FeedBody into a string ?
ConnectApi.FeedElement testPost = ConnectApi.ChatterFeeds.getFeedElement(Network.getNetworkId(),postId); String testMessage = vct.getTestMessage(); System.assertEquals(testMessage,testPost.body);