WASHINGTON — The political schism in the Democratic Party is playing out in the confirmation vote for Gina Haspel as CIA director, as support from red-state senators facing re-election bumps up against a more liberal flank eyeing potential 2020 presidential bids and rejecting the nominee over the agency’s clouded history of torture.

Haspel’s confirmation became all but certain with a favorable 10-5 vote Wednesday by the Senate Intelligence Committee. Yet the division in the Senate is set in large part by the election calendar, home-state geography and personal views — and it may define Democrats for years to come.

On one side is a growing list of a half-dozen Democrats whom many see as the future of the big-tent party. They are rural, noncoastal representatives of states won by President Donald Trump, places where some say the party needs to win back voters to grow beyond its urban core. Several of them have supported many of Trump’s nominees.

On the other side are those living in the comfort of blue-state incumbency, including liberal leaders who may take on Trump with their own campaigns for the White House. Their opposition to Haspel fuels a fired-up base of voters who are pushing a more progressive, battle-tested party to resist the Trump agenda.

With the Senate possibly voting as soon as Thursday on the new CIA director, “this is a soul-searching, defining moment for the Democratic Party,” said Elizabeth Beavers, the associate policy director at the liberal group Indivisible.

Beavers said senators are making a political miscalculation if they give their support to confirm a nominee “who has helped carry out torture.” It’s a vote, she said, “they’re going to have to explain for a long time to come.”

Haspel’s nomination reopened debate about the CIA’s now-defunct program of detaining terror suspects overseas at secret lock-ups and subjecting them to harsh interrogation techniques. Haspel supervised one of those detention sites in Thailand, but details of her work there have not been declassified.

Pressure on Democrats mounted late Wednesday after a third Republican, Sen. Jeff Flake of Arizona, announced his opposition to Haspel. He joined Sen. Rand Paul of Kentucky and fellow Arizona Sen. John McCain, whose long-distance rejection of Haspel as he battles brain cancer at home hit a political nerve. Considering the GOP’s slim 51-49 majority, Democrats could easily block the nominee, a career intelligence officer who would make history as the first woman to lead the CIA.

But Senate Minority Leader Chuck Schumer, D-N.Y., did not take that tack. In fact, rather than forcing his caucus in line against Haspel, Schumer continued to keep his vote to himself, a gesture that allows senators to chart their own courses without the overhang of leadership.

Most in the Democratic caucus are expected to vote against Haspel — with Sen. Kamala Harris of California among those setting the progressive pace with her “no” vote Wednesday in the committee.

Sens. Elizabeth Warren of Massacusetts and Bernie Sanders, the Vermont independent who caucuses with the Democrats, already announced their opposition. Warren tweeted that Haspel’s involvement in the torture program “makes her unfit to lead the CIA.” Other potential 2020 contenders, including Sens. Cory Booker of New Jersey and Kristen Gillibrand of New York, are also likely to vote against Haspel.

One red-state Democrat who has said he’ll oppose Haspel, Sen. Jon Tester of Montana, has already signaled his willingness to buck Trump. He drew the president’s Twitter ire after he publicly aired allegations against Veterans Affairs nominee Ronny Jackson, who later withdrew from consideration. It’s an election strategy that depends on keeping his state’s liberal base engaged as he fends off Trump’s attacks.

Those Democrats supporting Haspel did so with varying degrees of enthusiasm. West Virginia Sen. Joe Manchin, one of the most endangered incumbents in the fall election, has backed all but a few Trump nominees. In Haspel, he found “an unbelievable public servant” who is trying to keep the country safe. “I feel very comfortable and very good,” he said.

In a statement, Sen. Heidi Heitkamp of North Dakota acknowledged this was “was not an easy decision.” But she said she believes the president has the right to make his nominations, and as a senator she will “ensure Congress conducts robust oversight of the CIA under her leadership.”

The concerns raised by McCain ended up capturing the attention of more Democrats than Republicans, who largely shrugged off his advice. The 81-year-old was held captive and tortured during the Vietnam War and led efforts to ban the brutal post-9/11 interrogation techniques.

Sen. Angus King, the independent from Maine, also voted against Haspel at the committee, saying he felt she was not forthcoming about her role in the torture program. The decision became less defined by partisan lines, he said, and was instead left “for every member to decide.”

He sat between Democrats on the panel and, he noted, “we reached different conclusions.”