I had not, but now I have. Here is the example there:
my %data = (
multiple => 'to fail',
#multiple => [qw{this multi-value input will fail on the constraint
+below}],
single => 'to pass',
);
my %profile = (
required => [qw/
multiple
single
/],
constraints => {
multiple => [
{ name => 'constraint_1', constraint => qr/\w/ }, # pass
{ name => 'constraint_2', constraint => qr/\d/ }, # force fail
+
],
},
);
my $results = Data::FormValidator->check(\%data, \%profile);
The only difference, apart from using a regular expression, I see there is that they have the field name where the example from the documentation, and I, have a dummy nme, and where I, and the documentation, have the filed name as the first value in the array, the test does not. But, When I modify my code to resemble the code in that test, I still get the same error. This is so frustrating. Thanks Ted |