(self, inputFile, thermo=None, transport=None,
surface=None, output=None, quiet=True, extra=None, **kwargs)
| 17 | self.test_data_path = test_data_path |
| 18 | |
| 19 | def convert(self, inputFile, thermo=None, transport=None, |
| 20 | surface=None, output=None, quiet=True, extra=None, **kwargs): |
| 21 | if output is None: |
| 22 | output = Path(inputFile or thermo).stem # strip '.inp' |
| 23 | if inputFile is not None: |
| 24 | inputFile = self.test_data_path / inputFile |
| 25 | if thermo is not None: |
| 26 | thermo = self.test_data_path / thermo |
| 27 | if transport is not None: |
| 28 | transport = self.test_data_path / transport |
| 29 | if surface is not None: |
| 30 | surface = self.test_data_path / surface |
| 31 | if extra is not None: |
| 32 | extra = self.test_data_path / extra |
| 33 | output = self.test_work_path / (output + "-from-ck.yaml") |
| 34 | output.unlink(missing_ok=True) |
| 35 | ck2yaml.convert(inputFile, thermo_file=thermo, |
| 36 | transport_file=transport, surface_file=surface, out_name=output, |
| 37 | extra_file=extra, quiet=quiet, **kwargs) |
| 38 | return output |
| 39 | |
| 40 | def checkConversion(self, refFile, testFile): |
| 41 | ref = ct.Solution(refFile) |
no test coverage detected