summaryrefslogtreecommitdiff
path: root/t/06locus03.t
blob: bedf3a3a0fe9e79720434881094ed4ce77d4caea (plain)
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
# -*- perl -*-
use lib qw(t lib);
use strict;
use Test;
plan test => 1;

use TestPreproc;
my $obj = new TestPreproc -expand => [qw(locus include)];
ok($obj->dump_reformat_synclines,$obj->dump_expect);

__DATA__
!>httpd.conf
# Start of file
ServerRoot "$server_root"
ServerAdmin foo@example.net
Include vhost1.conf
Include vhost2.conf
PidFile logs/httpd.pid
!>vhost1.conf
<VirtualHost *:80>
   ServerName foo
   DocumentRoot a
</VirtualHost>
!>vhost2.conf
<VirtualHost *:80>
   ServerName bar
   DocumentRoot b
</VirtualHost>
!=
# {{$server_root/httpd.conf}}:1
# Start of file
# {{$server_root/httpd.conf}}:2
ServerRoot "$server_root"
# {{$server_root/httpd.conf}}:3
ServerAdmin foo@example.net
# {{$server_root/vhost1.conf}}:1-4
<VirtualHost *:80>
# {{$server_root/vhost1.conf}}:2
ServerName foo
# {{$server_root/vhost1.conf}}:3
DocumentRoot a
</VirtualHost>
# {{$server_root/vhost2.conf}}:1-4
<VirtualHost *:80>
# {{$server_root/vhost2.conf}}:2
ServerName bar
# {{$server_root/vhost2.conf}}:3
DocumentRoot b
</VirtualHost>
# {{$server_root/httpd.conf}}:6
PidFile logs/httpd.pid
!$    

Return to:

Send suggestions and report system problems to the System administrator.