Commit Graph

7 Commits (81550cab92aaacbca5db0d37c607dfd1707ce4c3)

Author SHA1 Message Date
Michael Chisholm 2cda97cf5e Changed STIX object initialization to formulate a property order
and process properties in that order.  This establishes iteration
order on object properties, making the object_properties() method
unnecessary.  So the latter method has been deleted.  All uses
of that method have been removed.

Removed unnecessary deepcopy() in STIXJSONEncoder, to improve
efficiency.  This uncovered a bug which had been affecting
STIXdatetime instances.  Not deepcopying doesn't trip the bug,
which can change serialization format.  This caused a unit
test to fail, which was checking serialization format.  I fixed
the unit test.

Fixed a bug in _STIXBase.__repr__ which caused it to omit all
properties with falsey values.  This caused several unit tests
to break, since they were written against the old buggy repr
format.  Notably, 'revoked=False' was never included in reprs
before, but it is now.
2021-07-06 20:32:58 -04:00
Emmanuelle Vargas-Gonzalez 6d285c47ae update test suite for use of .serialize(pretty=True) 2021-03-31 12:39:14 -04:00
Desai, Kartikey H 5fb69e1d44 Start updating test suites to fix issue 245 2019-01-22 21:25:09 -05:00
Emmanuelle Vargas-Gonzalez 51a499cb33 Formatting changes made by the new pre-commit hook 'add trailing commas'
closes #189
2018-07-13 11:10:05 -04:00
Emmanuelle Vargas-Gonzalez a042970a1f Merge branch 'master' of github.com:oasis-open/cti-python-stix2 into stix2.1 2018-07-11 09:41:42 -04:00
Emmanuelle Vargas-Gonzalez 5be1636b10 Update v20 tests to ensure right methods and classes are used 2018-07-05 15:23:25 -04:00
Emmanuelle Vargas-Gonzalez 3100fa1fb8 Move v20 tests to their own package 2018-07-03 07:02:57 -04:00