Commit 422223ce authored by Davis King's avatar Davis King

Added unit tests for new serialization syntax.

parent e314061e
......@@ -565,6 +565,20 @@ namespace
obj.assert_in_state_2();
*/
test_object obj2;
obj.set_state_1();
obj2.set_state_2();
dlib::serialize("serialization_test.dat") << obj << obj2;
obj.assert_in_state_1();
obj2.assert_in_state_2();
obj.set_state_2();
obj2.set_state_1();
obj.assert_in_state_2();
obj2.assert_in_state_1();
dlib::deserialize("serialization_test.dat") >> obj >> obj2;
obj.assert_in_state_1();
obj2.assert_in_state_2();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment