|
1234567891011121314151617181920 |
- """
- Makes a dummy post to the test server
- """
- import requests
- import json
- import abp
-
- def test_graph():
- N = 100
- g = abp.NXGraphState(range(N), vop="hadamard")
- for i in range(N-1):
- g.act_cz(i, i+1)
- g.layout()
- return g
-
- if __name__ == '__main__':
- data = json.dumps(test_graph().to_json(stringify=False))
- r = requests.post("http://localhost:5000/graph", data=data)
- print r.status_code, r.content
-
|