source: text-formbuilder/trunk/t/Text-FormBuilder.t @ 9

Last change on this file since 9 was 9, checked in by peter, 20 years ago

added some simple tests
worked on CGI framework script

File size: 803 bytes
Line 
1# Before `make install' is performed this script should be runnable with
2# `make test'. After `make install' it should work as `perl Text-FormBuilder.t'
3
4#########################
5
6# change 'tests => 1' to 'tests => last_test_to_print';
7
8use Test::More tests => 4;
9BEGIN { use_ok('Text::FormBuilder'); };
10
11#########################
12
13# Insert your test code below, the Test::More module is use()ed here so read
14# its man page ( perldoc Test::More ) for help writing this test script.
15
16my $p = Text::FormBuilder->new;
17isa_ok($p, 'Text::FormBuilder', 'new parser');
18isa_ok($p->parse_text('')->build->form, 'CGI::FormBuilder',  'generated CGI::FormBuilder object');
19
20my $p2 = Text::FormBuilder->parse_text('');
21isa_ok($p2, 'Text::FormBuilder', 'new parser (from parse_text as class method)');
Note: See TracBrowser for help on using the repository browser.