예제 #1
0
    def testGetValue(self):
        """Tests the GetValue function."""
        knowledge_base_object = knowledge_base.KnowledgeBase()

        plugin = macosx.MacOSXHostname()
        plugin.Run(self._searcher, knowledge_base_object)

        self.assertEqual(knowledge_base_object.hostname, u'Plaso\'s Mac mini')
예제 #2
0
파일: macosx_test.py 프로젝트: iwm911/plaso
    def testGetValue(self):
        """Tests the GetValue function."""
        pre_obj = event.PreprocessObject()
        plugin = macosx.MacOSXHostname(pre_obj)

        plugin.Run(self._searcher)

        hostname = getattr(pre_obj, 'hostname', None)
        self.assertEquals(hostname, u'Plaso\'s Mac mini')