ARLINGTON, Texas -- The Minnesota Twins snapped a five-game losing streak using contributions from two guys they will be counting on all season.

Designated hitter Kendrys Morales, who was hitting .172 in his last 15 games, drove in the game-winning run with a double in the ninth for the Twins, who also broke a nine-game losing skid on the road with a 3-2 victory over the Texas Rangers on Sunday afternoon.

Left-handed pitcher Glen Perkins struck out the side in the ninth to earn his 20th save and make a winner out of right-hander Kyle Gibson (7-6), who held Texas to two runs on eight hits over eight innings.

Gibson, who struck out three and walked no one, won for the third time in five starts in June. During the month he has a 3.16 ERA, which included giving up seven runs in two innings in his last start against the Los Angeles Angels. Before that loss, Gibson hadn't allowed a run in 22 consecutive innings.

"It was a big game for us," said Gibson, who has a 1.29 ERA in two starts against the Rangers this season. "All I was trying to do is give our team a chance to win and turn it around before we go home."

Sam Fuld, pinch-running for Josh Willingham, who got on reached base with a one-out single, scored the winning run from first on Morales' base hit that just found its way inside third base.

Minnesota shortstop Jorge Polanco, making his first major league start, had a double and RBI, and first baseman Joe Mauer extended his hitting streak to 10 games with a run-scoring single in the Twins two-run third.

"It was a tough road trip against tough teams," manager Ron Gardenhire said of the Twins six games against Los Angeles and Texas. "Gibby did exactly what we hoped he would. He was fantastic.

"Couple of breaks went our way and we won a ballgame. It all worked out for us."

Right-handed reliever Joakim Soria (1-3) took the loss for Texas (37-44). The game marked the first time since 2011 that Soria has allowed earned runs in consecutive outings.

Third baseman Adrian Beltre had a run-scoring hit in Texas' half of the first and catcher Robinson Chirinos, who was 3-for-3, tied the game with a solo home run in the fifth.

The Twins (37-43) avoided being swept for the fifth time this season.

Texas right-handed pitcher Colby Lewis earned a no-decision, giving up two runs on five hits over six innings. The game marked his first quality start of the season.

Lewis began the season with 13 consecutive non-quality starts, tying a major league record originally set by Seattle's Steve Trout in 1988.

"The ultimate goal is to win the game and we didn't win, but it was a quality start and built off last start," said Lewis, who went a season-high 6 1/3 innings in his last start, an loss to Detroit in which he surrendered four runs.

"I felt like I threw the ball real similar to last start," Lewis said. "Led Mauer the whole at-bat, threw one fastball in and he hits it for a base hit, so I felt like it was one of those days I really commanded the fastball."

The Rangers put runners at the corners with one out in the seventh, but Gibson worked around the jam by inducing a groundout double play from left fielder Michael Choice, 6-4-3.

The Twins took a lead in the third, starting with a leadoff double from third baseman Eduardo Escobar and another, off a check swing, with one out from Polanco. Polanco came one on first baseman Joe Mauer's run-scoring single.

"They did what they had to do to win the game, we didn't," Texas manager Ron Washington said. "Even if it was checked swings and all that stuff, it's baseball. You can't control what happens sometimes and you can't control what inning it's going to happen in."

NOTES: Sunday marked the halfway point in the season for Texas. The game was No. 80 for Minnesota. ... SS Jorge Polanco, currently the youngest player in the major leagues at 20, made his major league debut for Minnesota. Texas 2B Rougned Odor is also 20, though a few months older. ... Texas 3B Adrian Beltre entered play Sunday hitting .400 for the month of June, second in the big leagues to only to Houston's Jose Altuve (.414).