Development

Changeset 6964

You must first sign up to be able to contribute.

Changeset 6964

Show
Ignore:
Timestamp:
01/06/08 05:35:36 (11 months ago)
Author:
fabien
Message:

fixed unit test for sfValidatorErrorSchema

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/1.1/test/unit/validator/sfValidatorErrorSchemaTest.php

    r6954 r6964  
    4444$es->addError($es1, 'e3'); 
    4545$t->is($es->getCode(), 'max_length min_length e1 [max_length min_length] e2 [max_length e1 [max_length] e2 [min_length]] e3 [max_length e1 [max_length] e2 [min_length]]', '->addError() adds an error to the error schema'); 
    46 try 
    47 
    48   $es->addError($es1); 
    49   $t->fail('->addError() throws a LogicException if you try to add a global sfValidatorErrorSchema'); 
    50 
    51 catch (LogicException $e) 
    52 
    53   $t->pass('->addError() throws a LogicException if you try to add a global sfValidatorErrorSchema'); 
    54 
     46$es->addError($es1); 
     47$t->is($es->getCode(), 'max_length min_length max_length e1 [max_length min_length max_length] e2 [max_length min_length e1 [max_length] e2 [min_length]] e3 [max_length e1 [max_length] e2 [min_length]]', '->addError() adds an error to the error schema'); 
    5548 
    5649$es = new sfValidatorErrorSchema($v1, array($e1, 'e1' => $e1, 'e2' => $es1));