Q:

What happens to people who have never heard of Islam?

What happens to people who have never heard of Islam?
Is a man sent to hell because he is not a believer of Islam? Imagine this man is a good man on Earth and did some good things. Imagine this man is from Australia and he chose his religion based on his parents or environment he lives on or he didn't even heard of Islam.

A:

What happens to people who have never heard of Islam?

Those who have never heard of Islam will not be punished for their sins if they died in the state of disbelief. Allah says (what means):

Whoever is guided is only guided for [the benefit of] his soul. And
  whoever errs only errs against it. And no bearer of burdens will bear
  the burden of another. And never would We punish until We sent a
  messenger. - Qur'an 17:15

"And never would We punish until We sent a messenger" means that Allah won't punish those who never received the massage of Islam. Ibn Kathir explained this in the tafsir of the verse quoted above:

Allah tells us that out of His justice, He does not punish anyone
  until He has established proof against him by sending a Messenger to
  him, as He says:
(Every time a group is cast therein, its keeper will ask: "Did no
  warner come to you'' They will say: "Yes, indeed a warner did come to
  us, but we belied him and said: `Allah never sent down anything (of
  revelation); you are only in great error.''') (67:8-9) And,
(And those who disbelieved will be driven to Hell in groups, till,
  when they reach it, the gates thereof will be opened. And its keepers
  will say, "Did not the Messengers come to you from yourselves -
  reciting to you the verses of your Lord, and warning you of the
  meeting of this Day of yours'' They will say: "Yes,'' but the Word of
  torment has been justified against the disbelievers!) (39:71) And,
(Therein they will cry: "Our Lord! Bring us out, we shall do righteous
  good deeds, not (the evil deeds) that we used to do.'' (Allah will
  reply:) "Did We not give you lives long enough, so that whosoever
  would receive admonition could receive it And the warner came to you.
  So taste you (the evil of your deeds). For the wrongdoers there is no
  helper.'') (35:37) There are other Ayat which indicate that Allah will
  not make anyone enter Hell except after sending a Messenger to them.

If they won't be punished, then what will happen to them?

According to this (IslamQA) fatawa, they will be tested again in the day of resurrection. It cited the following hadith as its basis:

Al-Aswad ibn Saree reported that the Prophet of Allah (peace and
  blessings of Allah be upon him) said: 
“There are four (who will protest) to Allaah on the Day of
  Resurrection: the deaf man who never heard anything, the insane man,
  the very old man, and the man who died during the fatrah (the interval
  between the time of ‘Eesaa (Jesus, upon whom be peace) and the time of
  Muhammad SAWS (peace and blessings of Allah be upon him). 
The deaf man will say, ‘O Lord, Islam came but I never heard
  anything.’ The insane man will say, ‘O Lord, Islam came but the
  children ran after me and threw stones at me.’ The very old man will
  say, ‘O Lord, Islam came but I did not understand anything.’ The man
  who died during the fatrah will say, ‘O Lord, no Messenger from You
  came to me.’ He will accept their promises of obedience, then word
  will be sent to them to enter the Fire. By the One in Whose hand is
  the soul of Muhammad, if they enter it, it will be cool and safe for
  them.”

