Test case for KnowledgeBase