def test_set_model_history(): creators = [ factory.Creator(familyName='Koenig', givenName="Matthias", email="*****@*****.**", organization="Test organisation") ] sbmlns = libsbml.SBMLNamespaces(3, 1) doc = libsbml.SBMLDocument(sbmlns) model = doc.createModel() history.set_model_history(model, creators) # check if history was written correctly h = model.getModelHistory() assert h is not None assert h.getNumCreators() == 1 c = h.getCreator(0) assert 'Koenig' == c.getFamilyName() assert 'Matthias' == c.getGivenName() assert '*****@*****.**' == c.getEmail() assert 'Test organisation' == c.getOrganization()
<ol> <li>Redistributions of this SBML file must retain the above copyright notice, this list of conditions and the following disclaimer.</li> <li>Redistributions in a different form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.</li> </ol> This model is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p> </div> </body> """.format(settings.VERSION, '{}') creators = [ mc.Creator(familyName='Koenig', givenName='Matthias', email='*****@*****.**', organization='Humboldt University Berlin', site='http://livermetabolism.com') ] main_units = { 'time': 'h', 'extent': 'mmole', 'substance': 'mmole', 'length': 'm', 'area': 'm2', 'volume': UNIT_KIND_LITRE, } units = [ mc.Unit('h', [(UNIT_KIND_SECOND, 1.0, 0, 3600)], name="hour"), mc.Unit('kg', [(UNIT_KIND_KILOGRAM, 1.0)], name="kilogram"), mc.Unit('m', [(UNIT_KIND_METRE, 1.0)], name="meter"),
# -*- coding=utf-8 -*- """ Template information for the model creation. """ from datetime import datetime import sbmlutils.factory as factory # id : ('FamilyName', 'GivenName', 'Email', 'Organization') creators = [ factory.Creator( familyName="Koenig", givenName="Matthias", email="*****@*****.**", organization="Humboldt-University Berlin, Institute for Theoretical Biology", site="https://livermetabolism.com", ) ] terms_of_use = """ <div class="dc:provenance">The content of this model has been carefully created in a manual research effort.</div> <div class="dc:publisher">This file has been created by <a href="{site}" title="{given_name} {family_name}" target="_blank">{given_name} {family_name}</a>.</div> <h2>Terms of use</h2> <div class="dc:rightsHolder">Copyright © {year} {given_name} {family_name}.</div> <div class="dc:license"> <p>Redistribution and use of any part of this model, with or without modification, are permitted provided that the following conditions are met: <ol>
# -*- coding=utf-8 -*- """ Template information for the model creation. """ from datetime import datetime import sbmlutils.factory as factory # id : ('FamilyName', 'GivenName', 'Email', 'Organization') creators = [ factory.Creator( familyName='Koenig', givenName='Matthias', email='*****@*****.**', organization= 'Humboldt-University Berlin, Institute for Theoretical Biology', site="https://livermetabolism.com") ] terms_of_use = """ <div class="dc:provenance">The content of this model has been carefully created in a manual research effort.</div> <div class="dc:publisher">This file has been created by <a href="{site}" title="{given_name} {family_name}" target="_blank">{given_name} {family_name}</a>.</div> <h2>Terms of use</h2> <div class="dc:rightsHolder">Copyright © {year} {given_name} {family_name}.</div> <div class="dc:license"> <p>Redistribution and use of any part of this model, with or without modification, are permitted provided that the following conditions are met: <ol> <li>Redistributions of this SBML file must retain the above copyright notice, this list of conditions and the following disclaimer.</li>