You can't be sure you won't get food poisoning
but some basic observation steps can reduce the chance.
1) is the restaurant clean - incl dining room, kitchen (if you can see it) and bathroom area? 2) do the waiters and cooks appear healthy, clean, well-groomed? 3) does the food that other people have received look well-prepared? 4) are other people enjoying the food? 5) any past complaints?