<s> import unittest <EOL> import stix . data_marking as dm <EOL> from stix . test import EntityTestCase <EOL> from stix . test . common import information_source_test <EOL> class MarkingSpecificationTests ( EntityTestCase , unittest . TestCase ) : <EOL> klass = dm . MarkingSpecification <EOL> _full_dict = { <EOL> '<STR_LIT:id>' : "<STR_LIT:foo>" , <EOL> '<STR_LIT>' : "<STR_LIT>" , <EOL> '<STR_LIT:version>' : "<STR_LIT>" , <EOL> '<STR_LIT>' : "<STR_LIT>" , <EOL> '<STR_LIT>' : [ <EOL> { <EOL> '<STR_LIT>' : '<STR_LIT>' , <EOL> '<STR_LIT>' : "<STR_LIT>" , <EOL> } <EOL> ] <EOL> } <EOL> class MarkingStructureTests ( unittest . TestCase ) : <EOL> def test_xsi_type_required ( self ) : <EOL> d = { <EOL> '<STR_LIT>' : '<STR_LIT>' , <EOL> } <EOL> self . assertRaises ( ValueError , dm . MarkingStructure . from_dict , d ) <EOL> def test_xsi_type_required ( self ) : <EOL> d = { <EOL> '<STR_LIT>' : '<STR_LIT>' , <EOL> '<STR_LIT>' : "<STR_LIT>" , <EOL> } <EOL> self . assertRaises ( ValueError , dm . MarkingStructure . from_dict , d ) <EOL> class MarkingTests ( EntityTestCase , unittest . TestCase ) : <EOL> klass = dm . Marking <EOL> _full_dict = [ <EOL> { <EOL> '<STR_LIT:id>' : "<STR_LIT:foo>" , <EOL> '<STR_LIT>' : information_source_test . InformationSourceTests . _full_dict <EOL> } , <EOL> { <EOL> '<STR_LIT:id>' : "<STR_LIT:bar>" , <EOL> } , <EOL> ] <EOL> if __name__ == "<STR_LIT:__main__>" : <EOL> unittest . main ( ) </s>
