If the Oak is run with assertions enabled (-ea VM flag) then it throws AssertionError instead of javax.jcr.RepositoryException
Above code has following behaviour
- In JR2 - javax.jcr.RepositoryException: Invalid path://jcr:content
- In Oak with -ea - java.lang.AssertionError
- In Oak without -ea - Returns false.
For compatibility and also as per spec it should throw RepositoryException