Make the check for empty property expression stronger - it should trim the expression before checking for emptiness

(cherry picked from commit 0639719c03a08071db21162238fda9d5f5001dc5)
Remove a test that has been disabled long time ago.

Its JDK1.5 version works as expected

(cherry picked from commit 176e2b4f6b2a4cf8310ff1894373e3da65d2bf23)