Closed Onur101010 closed 4 years ago
The changes look fine. One thing that you should check is that you write the proper string to XML, like defined in the specifications and that you can read it again from the file. You could add another test that read from a file and write it to a String and you can read the SBMLDocument again from this String to check that the font family is still there.
I added a testclass with a dummy document with the font-family attribute set. The second test writeAndReadTest()
first writes the document to a String
and then reads it back and afterwards tests if the font-family
attribute is set correctly.
Changed
FontFamily
enum to support the Strings "monospace", "sans-serif" and "serif" instead of the uppercase names of the enum values. Also changingFontFamily
values to String is easier now because of the extra stored value (String), simply usingtoString()
is enough.In addition to that a new method
toFontFamily()
matches Strings and gives the value back asFontFamily
if it is contained in the enum.The standard storing value is String, therefore all classes using
FontFamily
as standard were updated too.