def test_codegeneration_for_all_models(self): path = str(os.path.realpath(os.path.join(os.path.dirname(__file__), os.path.join('..', 'models')))) params = list() params.append('--input_path') params.append(path) params.append('--logging_level') params.append('INFO') params.append('--target_path') params.append('target/models') params.append('--store_log') params.append('--dev') # try: main(params) self.assertTrue(True) # the goal is to reach this point without exceptions
def test_codegeneration_for_all_models(self): path = str( os.path.realpath( os.path.join(os.path.dirname(__file__), os.path.join('..', 'models')))) params = list() params.append('--input_path') params.append(path) params.append('--logging_level') params.append('INFO') params.append('--target_path') params.append('target/models') params.append('--store_log') params.append('--dev') exit_code = main(params) self.assertTrue(exit_code == 0)
def test_codegeneration_for_single_model(self): path = str(os.path.realpath(os.path.join(os.path.dirname(__file__), os.path.join('..', 'models', 'iaf_psc_exp.nestml')))) params = list() params.append('nestml') params.append('--input_path') params.append(path) params.append('--logging_level') params.append('INFO') params.append('--target_path') params.append('target/models') params.append('--store_log') params.append('--dev') exit_code = None with patch.object(sys, 'argv', params): exit_code = main() self.assertTrue(exit_code == 0)
# # PyNestML.py # # This file is part of NEST. # # Copyright (C) 2004 The NEST Initiative # # NEST is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 2 of the License, or # (at your option) any later version. # # NEST 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. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with NEST. If not, see <http://www.gnu.org/licenses/>. import sys from pynestml.frontend.pynestml_frontend import main """ This file represents the entry point to the PyNestML. """ if __name__ == '__main__': main(sys.argv[1:])
# # PyNestML.py # # This file is part of NEST. # # Copyright (C) 2004 The NEST Initiative # # NEST is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 2 of the License, or # (at your option) any later version. # # NEST 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. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with NEST. If not, see <http://www.gnu.org/licenses/>. import sys from pynestml.frontend.pynestml_frontend import main """ This file represents the entry point to the PyNestML. """ if __name__ == '__main__': sys.exit(main(sys.argv[1:]))