{ "argument" = "user.name=\"John Smith\" security.SMACK64=screen" }
}
+ (* Variable: valid_short_args
+A short argument value example. *)
+ let valid_short_args = "h /var/log/journal - - - - C\nh /var/log/journal - - - - +C\n"
+
+ (* Variable: valid_short_args_tree
+Tree for <valid_short_args> *)
+ let valid_short_args_tree =
+ {
+ "1"
+ { "type" = "h" }
+ { "path" = "/var/log/journal" }
+ { "mode" = "-" }
+ { "uid" = "-" }
+ { "gid" = "-" }
+ { "age" = "-" }
+ { "argument" = "C" }
+ }
+ {
+ "2"
+ { "type" = "h" }
+ { "path" = "/var/log/journal" }
+ { "mode" = "-" }
+ { "uid" = "-" }
+ { "gid" = "-" }
+ { "age" = "-" }
+ { "argument" = "+C" }
+ }
+
(* Variable: valid_age
Example with a complex age. *)
let valid_age = "v /var/tmp/js 4221 johnsmith - ~10d12h\n"
{ "argument" = "foo" }
}
+ (* Variable: mode3
+Mode field example with only three digits *)
+ let mode3 = "c+! /tmp/foo 755\n"
+
+ (* Variable: mode3_tree
+Tree for <mode3> *)
+ let mode3_tree =
+ {
+ "1"
+ { "type" = "c+!" }
+ { "path" = "/tmp/foo" }
+ { "mode" = "755" }
+ }
+
(************************************************************************
* Group: INVALID EXAMPLES
*************************************************************************)
(* Variable: invalid_type
Invalid example that contain invalid type (bad letter) *)
- let invalid_type = "q /var/tmp/js 0000 jonhsmith 60 1s foo\n"
+ let invalid_type = "e /var/tmp/js 0000 jonhsmith 60 1s foo\n"
(* Variable: invalid_type_num
Invalid example that contain invalid type (numeric) *)
test Tmpfiles.lns get complex_arg = complex_arg_tree
+ test Tmpfiles.lns get valid_short_args = valid_short_args_tree
+
test Tmpfiles.lns get valid_second = valid_second_tree
test Tmpfiles.lns get valid_days = valid_days_tree
test Tmpfiles.lns get valid_base = valid_base_tree
+ test Tmpfiles.lns get mode3 = mode3_tree
+
(* failure cases *)