[292939] Improve the performance of metadata query
diff --git a/jsf/tests/org.eclipse.jst.jsf.metadata.tests/src/org/eclipse/jst/jsf/common/metadata/tests/MetaDataQueryHelperTests.java b/jsf/tests/org.eclipse.jst.jsf.metadata.tests/src/org/eclipse/jst/jsf/common/metadata/tests/MetaDataQueryHelperTests.java
index 8b6262a..1e18d15 100644
--- a/jsf/tests/org.eclipse.jst.jsf.metadata.tests/src/org/eclipse/jst/jsf/common/metadata/tests/MetaDataQueryHelperTests.java
+++ b/jsf/tests/org.eclipse.jst.jsf.metadata.tests/src/org/eclipse/jst/jsf/common/metadata/tests/MetaDataQueryHelperTests.java
@@ -246,5 +246,22 @@
 			//pass
 		}
 	}
+	
+	public void testGetEntityBeyondMDDepth() {
+		Entity entity = TaglibDomainMetaDataQueryHelper.getEntity(baseContext, "loaded/does_not_exist/nor_this");
+		assertNull(entity);
+	}
+	
+	public void testGetEntityBadEntityKey() {
+		Entity entity = TaglibDomainMetaDataQueryHelper.getEntity(baseContext, "");
+		assertNull(entity);
+
+		entity = TaglibDomainMetaDataQueryHelper.getEntity(baseContext, null);
+		assertNull(entity);
+		
+		entity = TaglibDomainMetaDataQueryHelper.getEntity(baseContext, "/");
+		assertNull(entity);
+
+	}
 
 }
diff --git a/jsf/tests/org.eclipse.jst.pagedesigner.tests/src/org/eclipse/jst/pagedesigner/tests/tagcreator/TestDefaultTagCreatorJSP.java b/jsf/tests/org.eclipse.jst.pagedesigner.tests/src/org/eclipse/jst/pagedesigner/tests/tagcreator/TestDefaultTagCreatorJSP.java
index 60313ed..4b1d825 100644
--- a/jsf/tests/org.eclipse.jst.pagedesigner.tests/src/org/eclipse/jst/pagedesigner/tests/tagcreator/TestDefaultTagCreatorJSP.java
+++ b/jsf/tests/org.eclipse.jst.pagedesigner.tests/src/org/eclipse/jst/pagedesigner/tests/tagcreator/TestDefaultTagCreatorJSP.java
@@ -11,6 +11,7 @@
 package org.eclipse.jst.pagedesigner.tests.tagcreator;
 
 import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
+import org.eclipse.wst.xml.core.internal.provisional.contentmodel.CMDocType;
 
 public class TestDefaultTagCreatorJSP extends BaseDefaultTagCreatorTestCase 
 {
@@ -33,7 +34,7 @@
 
     public void testIncludeDirective() throws Exception
     {
-        doCreateTest(TagIdentifierFactory.createJSPTagWrapper("jsp11", "jsp:directive.include"), "jsp", "jsp", 349,false, null);
-        doCreateTest(TagIdentifierFactory.createJSPTagWrapper("jsp11", "jsp:directive.include"), "jspx", "jspx", 492,false, null);
+        doCreateTest(TagIdentifierFactory.createJSPTagWrapper(CMDocType.JSP11_DOC_TYPE, "jsp:directive.include"), "jsp", "jsp", 349,false, null);
+        doCreateTest(TagIdentifierFactory.createJSPTagWrapper(CMDocType.JSP11_DOC_TYPE, "jsp:directive.include"), "jspx", "jspx", 492,false, null);
     }
 }