rm odltools egg files
[netvirt.git] / resources / tools / odltools / odltools / ovs / tests / test_flows.py
1 import unittest
2
3 from ovs import request
4
5 from odltools import logg
6 from odltools.ovs import flows
7
8
9 class TestFlows(unittest.TestCase):
10     def setUp(self):
11         logg.Logger()
12         self.filename = "./resources/flow_dumps.3.txt"
13         self.data = request.read_file(self.filename)
14         self.flows = flows.Flows(self.data)
15
16     def test_process_data(self):
17         print "pretty_print:\n{}".format(self.flows.pretty_print(self.flows.pdata))
18
19     def test_format_data(self):
20         print "pretty_print:\n{}".format(self.flows.pretty_print(self.flows.fdata))
21
22     def test_write_file(self):
23         self.flows.write_fdata("/tmp/flow_dumps.3.out.txt")
24
25 if __name__ == '__main__':
26     unittest.main()