There are way more sources for Socrates than Plato. He is mentioned by several contemporaries. We may assume that what impelled Plato to write down Socrates' dialogues was that he was incensed that Socrates had been put to death unjustly.
Likewise for Jesus, though we are not at all confident about the author(s) of the first Christian texts. Apart from Paul, of course, and not only had he never met Jesus, he was busy setting up the organisation and had different priorities.
I think it's a reasonable assumption that Jesus lived and taught and said many of the things recorded.
That doesn't follow that the various legends and dogmas that arose afterwards may likewise be assumed to be true. The concept of the Trinity, for example, was supplied by Plotinus, quite a long time after the death of Christ.