22 |
my $max = 10000; |
my $max = 10000; |
23 |
|
|
24 |
if (-r $dict) { |
if (-r $dict) { |
25 |
print STDERR " making B-Tree from $max words in $dict\n"; |
diag "making B-Tree from $max words in $dict"; |
26 |
|
|
27 |
open(D, "$dict") || die "can't open '$dict': $!"; |
open(D, "$dict") || die "can't open '$dict': $!"; |
28 |
|
|
51 |
print T $t->to_string; |
print T $t->to_string; |
52 |
close(T); |
close(T); |
53 |
} |
} |
54 |
print STDERR " words.txt created\n"; |
diag "words.txt created"; |
55 |
|
|
56 |
if (open(T,"> words.dot")) { |
if (open(T,"> words.dot")) { |
57 |
print T $t->to_dot; |
print T $t->to_dot; |
58 |
close(T); |
close(T); |
59 |
} |
} |
60 |
print STDERR " words.dot created\n"; |
diag "words.dot created"; |
61 |
|
|
62 |
cmp_ok($t->to_jsfind("./html/words"), '==', $max, " jsfind index"); |
cmp_ok($t->to_jsfind("./html/words"), '==', $max, " jsfind index"); |
63 |
} |
} |