Due to the pain of death, the tissues within the face and jaw become taut/stretched and then return back to their original state. Due to this tension, sometimes, it appears that the dead person is smiling. However, some ignorant people use this as a PROOF for claiming the dead person to be from those who achieved salvation and the person is from inhabitants of paradise. Even though, there are quite many examples of Non Muslims, Atheists, Jews, Christians and Innovators who died with such a condition.
Therefore, A Smiling Face is NOT a guarentee that the person will go to Jannah.