예제 #1
0
    def test_get_import_source(self):
        from libcellml import Error, ImportSource

        # ImportSourcePtr getImportSource()
        e = Error()
        self.assertIsNone(e.getComponent())
        name = 'uri'
        i = ImportSource()
        i.setId(name)
        e.setImportSource(i)
        self.assertIsInstance(e.getImportSource(), ImportSource)
        self.assertEqual(e.getImportSource().getId(), name)
예제 #2
0
    def test_set_import_source(self):
        from libcellml import Error, ImportSource

        # void setImportSource(const ImportSourcePtr &import)
        e = Error()
        e.setImportSource(ImportSource())