Conversation
…me from output json
dave-doty
left a comment
There was a problem hiding this comment.
Looks good, although in the diff (the "File changed" tab on GitHub) I don't see the new unit tests anymore. Are the new unit tests there? Maybe I'm only looking at a diff between the last two commits, rather than a diff between the dev branch and this one.
Are you looking for these? New unit tests for import: New unit tests for export: You might need to click on Load Diff in test/scadnano_test.py to see it |
dave-doty
left a comment
There was a problem hiding this comment.
Ah, it was hidden by the "large diffs not rendered by default".
Description
The two main changes are the cadnano export functions and unit testing
Cadnano export refactor
The cadnano export functions has been refactored
Before
Design.to_cadnano_v2export_cadnano_v2After
Design.to_cadnano_v2_serializableDesign.to_cadnano_v2_jsonwrite_cadnano_v2_filein order to better align with the existing APIs for scadnano and oxdna file exports.
Unit tests no longer output files
Calls to
write_scadnano_fileandwrite_cadnano_v2_file(previouslyexport_cadnano_v2) have been commented out.Calls to
write_cadnano_v2_file(previouslyexport_cadnano_v2) have been replaced by invokingDesign.to_cadnano_v2_jsonfunction.Motivation and Context
This change was needed in order to make the APIs for the cadnano export consistent with the scadnano and oxdna file exports. In addition, the unit testing has been cleaned up so that they no longer write files, which is unnecessary.
How Has This Been Tested?
Ran unit tests. Also uncommented the
write_cadnano_v2_fileand verified that the outputted cadnano files can be opened on cadnano and that the design matches what is expected based on the scadnano design. Also verified that inputted cadnano files are properly exported to scadnano.