So here's an unrealistic scenario.
Rangers win 3, lose 3
Astros win 4, lose 1
Angels win 5, lose 1
My head hurts. What happens?
Assuming Minnesota is not in the mix for the wild card at that point, it goes to the tie-breaker rules, which designates the teams as A, B and C. Given that the Astros have season series over the Angels, the Angels would have it over the Rangers and the Rangers would have it over the Astros, it goes to the next tie breaker, which is winning percentage against the other two teams. The Angels would have the highest, followed by the Rangers.
EDIT: I screwed that up. Following from above:
The Angels get to chose their designation (A, B or C), followed the Rangers, and the Astros would have what's left. Team A would host Team B, with the loser eliminated. The winner of that game would host Team C, with the winner being the division champ and the loser being the wild card. So if the Angels chose to be C, they'd clinch a post-season spot, but would have to play the division tiebreaker on the road.