Server IP : 127.0.0.2 / Your IP : 3.145.80.205 Web Server : Apache/2.4.18 (Ubuntu) System : User : www-data ( ) PHP Version : 7.0.33-0ubuntu0.16.04.16 Disable Function : disk_free_space,disk_total_space,diskfreespace,dl,exec,fpaththru,getmyuid,getmypid,highlight_file,ignore_user_abord,leak,listen,link,opcache_get_configuration,opcache_get_status,passthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,php_uname,phpinfo,posix_ctermid,posix_getcwd,posix_getegid,posix_geteuid,posix_getgid,posix_getgrgid,posix_getgrnam,posix_getgroups,posix_getlogin,posix_getpgid,posix_getpgrp,posix_getpid,posix,_getppid,posix_getpwnam,posix_getpwuid,posix_getrlimit,posix_getsid,posix_getuid,posix_isatty,posix_kill,posix_mkfifo,posix_setegid,posix_seteuid,posix_setgid,posix_setpgid,posix_setsid,posix_setuid,posix_times,posix_ttyname,posix_uname,pclose,popen,proc_open,proc_close,proc_get_status,proc_nice,proc_terminate,shell_exec,source,show_source,system,virtual MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /usr/share/augeas/lenses/dist/tests/ |
Upload File : |
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" } }