3 #****h* ROBODoc System Tests/ROBODoc Configuration File
5 # Test stuff that can be specified in the robodoc.rc file.
11 use Test::More 'no_plan';
15 #****x* ROBODoc Configuration File/Custom Header Markers
17 # Test whether custum header markers can be specified.
41 my $rc_file = <<'EOF';
53 add_source( "test.c", $source );
54 add_source( "robodoc.rc", $rc_file );
55 my ($out, $err) = runrobo( qw(--src Src --doc Doc --multidoc
56 --test --rc Src/robodoc.rc ) );
57 is( $out, '', 'no output' );
58 is( $err, '', 'no error' );
59 my $documentation = XMLin( 'Doc/test_c.xml' );
60 my $header = $documentation->{'header'};
61 # print Dumper( $documentation );
62 isnt ( $header->{'Foo/foo'}, undef, 'There is a header named Foo/foo' );
63 isnt ( $header->{'Test/test'}, undef, 'There is a header named Test/foo' );
69 #****x* ROBODoc Configuration File/line-endings.
71 # ROBODoc should not care about the kind of line-endings that
72 # are used. Either cr/lf or cr, or even lf should work without
73 # any problem. We test this with two .rc files that have
74 # different kind of line-endings.
85 # A rc file with 'unix' line-endings.
86 my $config = read_hexdump( 'TestData/robodoc_unix_rc.xxd' );
87 add_configuration( "test.rc", $config, 'binary' );
88 add_source( "test.rc", $source );
90 my ( $out, $err ) = runrobo(qw(
94 --singledoc --test --nopre ));
96 is( $out, '', 'No ouput' );
97 is( $err, '', '... and no error' );
100 # A rc file with 'windows' line-endings.
101 $config = read_hexdump( 'TestData/robodoc_windows_rc.xxd' );
102 add_configuration( "test.rc", $config, 'binary' );
103 add_source( "test.rc", $source );
105 ( $out, $err ) = runrobo(qw(
109 --singledoc --test --nopre ));
111 is( $out, '', 'No ouput' );
112 is( $err, '', '... and no error' );