Anders and Briegel in Python
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 line
346B

  1. from abp import GraphState
  2. from abp import clifford
  3. from demograph import demograph
  4. import time
  5. import json
  6. def test_json_basic():
  7. """ Test that we can export to JSON """
  8. g = demograph()
  9. js = g.to_json()
  10. assert "edges" in js
  11. assert "nodes" in js
  12. e = GraphState()
  13. assert e != g
  14. e.from_json(js)
  15. assert e == g