I was curious about your question, and so went and did some research... here's the most susinct that I found.
The infancy gospel of Thomas is part of the Gnostic writings. They contain accounts that are not consistant with the rest of scripture, and therefore were not included in the Bible. In this Gospel, Jesus is seen a spoiled child who is vindictive, and takes retribution on those who "wrong" him.
Here's what the commentator says:
"With one exception, virtually no one believes this story is true. First, the story wasnt written until about 100 to 150 years after Jesus death, which is much later than our earliest sources about Jesus.
Second, our earliest sources about Jesus are all Jewish and the Infancy Gospel of Thomas shows no knowledge of first century Judaism.
Third, according to the Gospel of John, Jesus did his very first miracle, not when he was a child, but as an adult when he turned water into wine.
Virtually no scholars (or anyone else) believes that the stories about Jesus in the Infancy Gospel of Thomas are truethe only exception is Muslims. Muslims believe the story is true because Muhammadwho lived more than 300 years after the story was writtenseems to have believed it! At least twice in the Quran Muhammad talks about how Jesus took a clay bird and made it come alive (Sura 3.49 and 5.10).
This creates a dilemma for Muslims. Since they believe that the teachings in the Quran were given to Muhammad from God word-for-word, they are forced to believe a story which no one but Muslims believe, written 100 to 150 years after Jesus lived. If the clay bird story isnt true, it would mean that Muhammad did not get it word-for-word from God, and that would place the Quran, the prophethood of Muhammad and all of Islam in question."
Hope that helps.