示例#1
0
 function testReturnValues()
 {
     $entry = new PelEntryAscii(42);
     $entry = new PelEntryAscii(42, 'foo bar baz');
     $this->assertEquals($entry->getComponents(), 12);
     $this->assertEquals($entry->getValue(), 'foo bar baz');
 }
示例#2
0
文件: ascii.php 项目: alamehor/pel
 function testReturnValues()
 {
     $pattern = new PatternExpectation('/Missing argument 1 for lsolesen.pel.PelEntryAscii::__construct()/');
     $this->expectError($pattern);
     $this->expectError('Undefined variable: tag');
     $entry = new PelEntryAscii();
     $entry = new PelEntryAscii(42);
     $entry = new PelEntryAscii(42, 'foo bar baz');
     $this->assertEqual($entry->getComponents(), 12);
     $this->assertEqual($entry->getValue(), 'foo bar baz');
 }