Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

Commit

Permalink
fix InputFilter tests
Browse files Browse the repository at this point in the history
- remove refs to Alpha filter
  • Loading branch information
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/InputTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -135,19 +135,19 @@ public function testIsValidReturnsFalseIfValidationChainFails()
public function testIsValidReturnsTrueIfValidationChainSucceeds()
{
$input = new Input('foo');
$input->setValue('bar');
$validator = new Validator\Alpha();
$input->setValue('123');
$validator = new Validator\Digits();
$input->getValidatorChain()->addValidator($validator);
$this->assertTrue($input->isValid());
}

public function testValidationOperatesOnFilteredValue()
{
$input = new Input('foo');
$input->setValue(' bar ');
$input->setValue(' 123 ');
$filter = new Filter\StringTrim();
$input->getFilterChain()->attach($filter);
$validator = new Validator\Alpha();
$validator = new Validator\Digits();
$input->getValidatorChain()->addValidator($validator);
$this->assertTrue($input->isValid());
}
Expand Down

0 comments on commit ef323df

Please sign in to comment.