()
| 903 | |
| 904 | #[test] |
| 905 | fn test_file_add() { |
| 906 | let graph_op: GraphOp<Hash> = GraphOp::FileAdd { |
| 907 | add_name: test_new_vertex(), |
| 908 | add_inode: test_new_vertex(), |
| 909 | contents: Some(test_new_vertex()), |
| 910 | path: "README.md".to_string(), |
| 911 | encoding: Some(Encoding::Utf8), |
| 912 | }; |
| 913 | |
| 914 | assert!(graph_op.is_file_operation()); |
| 915 | assert!(!graph_op.is_content_edit()); |
| 916 | assert_eq!(graph_op.path(), Some("README.md")); |
| 917 | assert_eq!(graph_op.encoding(), Some(Encoding::Utf8)); |
| 918 | assert_eq!(graph_op.type_name(), "FileAdd"); |
| 919 | } |
| 920 | |
| 921 | #[test] |
| 922 | fn test_file_del() { |
nothing calls this directly
no test coverage detected