File: 12confmerge.t

package info (click to toggle)
libsql-abstract-perl 2.000001-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 744 kB
  • sloc: perl: 3,443; makefile: 8
file content (22 lines) | stat: -rw-r--r-- 589 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
use strict;
use warnings;

use Test::More;

use SQL::Abstract::Tree;

my $tree = SQL::Abstract::Tree->new({
   profile  => 'console',
   colormap => {
      select     => undef,
      'group by' => ['yo', 'seph'] ,
   },
});

is $tree->newline, "\n", 'console profile appears to have been used';
ok !defined $tree->colormap->{select}, 'select correctly got undefined from colormap';

ok eq_array($tree->colormap->{'group by'}, [qw(yo seph)]), 'group by correctly got overridden';
ok ref $tree->colormap->{'order by'}, 'but the rest of the colormap does not get blown away';

done_testing;