HOUSTON (Reuters) - BP Plc said on Thursday no oil was leaking into the Gulf of Mexico for the first time since its huge spill began in April as it conducted pressure tests on its blown-out deep-sea well.

For the test, BP closed valves and vents on a tight-sealing containment cap installed atop its ruptured well earlier this week. Initial results early in the test showed the cap had completely contained the flow of oil, BP said.

“It’s a great sight but it’s far from the finish line,” Doug Suttles, a senior BP executive, told reporters.

BP’s U.S. shares initially jumped 10 percent after the company announced that its test had shut off the flow of oil.

President Barack Obama called the end of the flow of oil into the ocean a “positive sign,” but cautioned that the latest effort was still in the testing phase. The spill has caused an economic and environmental disaster along the U.S. Gulf Coast.

As the company pushed ahead on the spill-control effort, U.S. energy company Apache Corp was moving forward on a possible $10 billion deal for some BP properties, including major assets in Alaska, CNBC reported.

After a delay to fix a leak, BP began the test on Thursday afternoon on the cap that could stop all or most of the flow of crude that has been polluting the ocean and coastline since April 20 in the worst offshore oil spill in U.S. history.

The test, which could last between six to 48 hours, gauges pressure in the well -- which extends 2.5 miles under the seabed -- to assess its condition. Officials said it will show whether the cap can safely shut off the flow from the well if oil-capture vessels at the surface must disconnect.

The U.S. Coast Guard has described the containment cap as at best a temporary fix to the leak while BP finishes two relief wells that it is drilling that are intended to intersect the blown-out well and permanently seal it next month.

The test is intended to determine whether the structure of the lengthy well is damaged or intact. Retired Coast Guard Admiral Thad Allen, the U.S. government’s point man on the spill, compared the test to placing one’s thumb over the end of a garden hose -- if the pressure does not increase that means there is a leak somewhere.

Regarding the BP well, a build-up of pressure would signal that the well is intact, which would make it easier to seal it with the relief wells.

The cap is a crucial step toward a multi-vessel oil-capture system that is hurricane-ready and can collect up to 80,000 barrels (3.34 million gallons/12.7 million liters) per day.

That should be more than enough to capture the whole well output, as estimates put the spill rate between 35,000 barrels (1.47 million gallons/5.56 million liters) and 60,000 barrels (2.5 million gallons/9.5 million liters) a day.

Allen backed away from earlier assurances that the new cap would be used to completely seal the well until the relief wells eventually kill it with heavy mud and cement.

Allen said the cap could shut the well, but might be used only to block the flow during emergency situations like a hurricane when BP’s surface containment effort would be suspended. “The intention of the capping stack was never to close in the well per se,” Allen said in New Orleans.

BP STOCK

Reports that Apache was seeking $6 billion to $7 billion for the purchase helped boost BP’s U.S. shares from midday. The shares then rose further on the initial test results and ended up 7.6 percent at $38.92.

Slideshow ( 19 images )

“It’s been one of those headline things we’ve heard for 87 days, lots of people waiting for some good news,” said John Massey, portfolio manager at Sunamerica Asset Management in Jersey City, New Jersey.

Analysts surveyed by Reuters Insider predict that BP will spend between $63 billion to $100 billion over the next 15 years in fines, cleanup costs and legal costs.

BP’s shares have been ravaged since the well rupture, with $100 billion in market value being knocked off at one stage, before a three-week rally sparked by takeover talk, speculation about investment by a sovereign wealth fund and hopes that the well would be capped.

The news that it had finally stopped the leak -- at least during the test -- was a bit of good news for the British company, which has seen its share value plummet and reputation battered since the April 20 rig explosion that killed 11 workers and led to the spill of millions of gallons of oil.

Slideshow ( 19 images )

BP also faced new measures in the U.S. Congress. Lawmakers are mulling a range of new laws that could require tougher safety regulations on offshore drilling or bar companies like BP from new offshore exploration leases.

The U.S. government, which has vowed to make BP pay for fixing the well and all cleanup efforts, told the oil giant that it was responsible for paying all royalties on the oil it is collecting from the ruptured well.

Currently, energy companies pay the government a royalty rate of up to 18.75 percent of the value of the oil and gas drilled in offshore tracts.

Through its containment systems, BP has collected or burned more than 800,000 barrels of oil.

The Gulf spill has soiled hundreds of miles/kilometers of shoreline, shut down about a third of Gulf fisheries and hurt tourism and fishing in all five U.S. Gulf states. It has also created problems for Obama as the government works to respond to the crisis while area residents struggle financially.

“It’s a great thing, it’s a wonderful thing,” said Jerome DeGree in Larose, Louisiana when he heard that BP had at least temporarily stopped the oil from gushing into the ocean.

“This has been hurting this whole area,” the shallow-water oil driller said. “I couldn’t buy my shrimp, I couldn’t buy my oysters, I couldn’t take my boat out.”

In an issue unrelated to the spill, but illustrating the pressure BP faces in the United States, the company confirmed on Thursday that it had lobbied the British government to speed up a prisoner transfer agreement with Libya in late 2007.

In August 2009, Britain released a Libyan convicted of blowing up a U.S. plane, angering the United States. Many of the 270 dead in the 1988 Lockerbie bombing were American.

The U.S. Senate Foreign Relations Committee said it would hold a hearing on the issue on July 29.