The same issues that triggered the denial of the B2 visa remain in play, and thus could cause an immigration officer to deny you entry under the visa waiver program. It would be safer to enter with a visa; if you continue to be denied you can expect that the result would be the same at the border, but without your investment in a plane ticket.

