After an afternoon of negotiations on Wednesday, the NBA and players union both expressed hope the league can avoid a lockout when its collective bargaining agreement expires at the end of the month.

The two sides said progress had been made during a four-hour session at a downtown hotel. League and union representatives also plan to meet in Dallas on June 7-8 when the NBA Finals move to Texas next week.

The league’s CBA is set to expire on June 30. A lockout would likely begin the next day if there is no new agreement in place.

“It’s still our hope that there may be a deal here to be done,” NBA commissioner David Stern said. “We’re going to test it to the limits. If we’re wrong, we’re wrong.”

Players union executive director Billy Hunter has previously said he was “99 percent sure” a work stoppage would take place this summer. But after Wednesday’s talks, he expressed new hope, saying the discussions were “much more fluid than we’ve had in some time.” Stern added that while both sides are still “quite far apart,” there is also enough time to hammer out a deal.

“I’m hopeful,” Hunter said. “We know the pressure is building. And if anything is going to happen, it’s going to have to happen between now and June 30. We’re going to make every effort to see if we can make a deal. If we don’t, we don’t. It’s not going to be for a lack of trying.”