The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.
use strict;
use warnings;

use Test::More tests => 3;

use HTML::FormFu;

my $form = HTML::FormFu->new;

$form->element('Text')->name('foo');
$form->element('Text')->name('bar');
$form->element('Text')->name('baz');

$form->process(
    {   foo => 'a',
        bar => [ 'b', 'c' ],
    } );

is_deeply( $form->param_array('foo'), ['a'] );

is_deeply( $form->param_array('bar'), [ 'b', 'c' ] );

is_deeply( $form->param_array('baz'), [] );