/usr/share/augeas/lenses/dist/tests/test_properties.aug is in augeas-lenses 1.4.0-0ubuntu1.1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 | module Test_properties =
let conf = "
# Test tomcat properties file
#tomcat.commented.value=1
# config
tomcat.port = 8080
tomcat.application.name=testapp
tomcat.application.description=my test application
property.with_underscore=works
empty.property=
empty.property.withtrailingspaces= \n! more comments
key: value
key2:value2
key3 :value3
key4:=value4
long.description=this is a description that happens to span \
more than one line with a combination of tabs and \
spaces \ \nor not
# comment break
short.break = a\
b
=empty_key
=empty_key
cheeses
spaces only
multi spaces
indented spaces
\= =A
space and = equals
space with \
multiline
escaped\:colon=value
escaped\=equals=value
escaped\ space=value
"
(* Other tests that aren't supported yet
overflow.description=\
just wanted to indent it
*)
let lns = Properties.lns
test lns get conf =
{ }
{ "#comment" = "Test tomcat properties file" }
{ "#comment" = "tomcat.commented.value=1" }
{ "#comment" = "config" }
{ "tomcat.port" = "8080" }
{ "tomcat.application.name" = "testapp" }
{ "tomcat.application.description" = "my test application" }
{ "property.with_underscore" = "works" }
{ "empty.property" }
{ "empty.property.withtrailingspaces" }
{ "!comment" = "more comments" }
{ "key" = "value" }
{ "key2" = "value2" }
{ "key3" = "value3" }
{ "key4" = "=value4" }
{}
{ "long.description" = " < multi > "
{ = "this is a description that happens to span " }
{ = "more than one line with a combination of tabs and " }
{ = "spaces " }
{ = "or not" }
}
{}
{ "#comment" = "comment break" }
{}
{ "short.break" = " < multi > "
{ = "a" }
{ = "b" }
}
{}
{ = "empty_key" }
{ = "empty_key" }
{}
{ "cheeses" }
{}
{ "spaces" = "only" }
{ "multi" = "spaces" }
{ "indented" = "spaces" }
{}
{ "\\=" = "A" }
{ "space" = "and = equals" }
{ "space" = " < multi > "
{ = "with " }
{ = "multiline" }
}
{}
{ "escaped\:colon" = "value" }
{ "escaped\=equals" = "value" }
{ "escaped\ space" = "value" }
test lns put conf after
set "tomcat.port" "99";
set "tomcat.application.host" "foo.network.com"
= "
# Test tomcat properties file
#tomcat.commented.value=1
# config
tomcat.port = 99
tomcat.application.name=testapp
tomcat.application.description=my test application
property.with_underscore=works
empty.property=
empty.property.withtrailingspaces= \n! more comments
key: value
key2:value2
key3 :value3
key4:=value4
long.description=this is a description that happens to span \
more than one line with a combination of tabs and \
spaces \ \nor not
# comment break
short.break = a\
b
=empty_key
=empty_key
cheeses
spaces only
multi spaces
indented spaces
\= =A
space and = equals
space with \
multiline
escaped\:colon=value
escaped\=equals=value
escaped\ space=value
tomcat.application.host=foo.network.com
"
(* GH issue #19: value on new line *)
test lns get "k=\
b\
c\n" =
{ "k" = " < multi > "
{ } { = "b" } { = "c" } }
test lns get "tomcat.util.scan.DefaultJarScanner.jarsToSkip=\
bootstrap.jar,commons-daemon.jar,tomcat-juli.jar\n" =
{ "tomcat.util.scan.DefaultJarScanner.jarsToSkip" = " < multi > "
{ } { = "bootstrap.jar,commons-daemon.jar,tomcat-juli.jar" } }
|