Changeset 412 for trunk/UnitTestContrib/test/unit/FormDefTests.pm
- Timestamp:
- 11/03/08 13:48:21 (4 years ago)
- File:
-
- 1 edited
-
trunk/UnitTestContrib/test/unit/FormDefTests.pm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/UnitTestContrib/test/unit/FormDefTests.pm
r14 r412 176 176 } 177 177 178 sub test_makeFromMeta { 179 my $this = shift; 180 $this->{twiki}->{store}->saveTopic( 181 $this->{twiki}->{user}, $this->{test_web}, 'SplodgeOne', <<FORM); 182 %META:FORM{name="NonExistantForm"}% 183 %META:FIELD{name="Ecks" attributes="" title="X" value="Blah"}% 184 FORM 185 my ($meta, $text) = 186 $this->{twiki}->{store}->readTopic( 187 undef, $this->{test_web}, 'SplodgeOne'); 188 my $form = new TWiki::Form( 189 $this->{twiki}, $this->{test_web}, 'NonExistantForm', $meta); 190 my $f = $form->getField('Ecks'); 191 $this->assert_str_equals('', $f->getDefaultValue()); 192 $this->assert_str_equals('Ecks', $f->{name}); 193 $this->assert_str_equals('X', $f->{title}); 194 $this->assert_str_equals('', $f->{size}); 195 } 196 178 197 1;
Note: See TracChangeset
for help on using the changeset viewer.
