Respect\Validation\Rules\AbstractWrapperTest::testShouldUseWrappedToValidate PHP Method

testShouldUseWrappedToValidate() public method

    public function testShouldUseWrappedToValidate()
    {
        $input = 'Whatever';
        $validatable = $this->createMock(Validatable::class);
        $validatable->expects($this->once())->method('validate')->with($input)->will($this->returnValue(true));
        $wrapper = $this->getMockForAbstractClass(AbstractWrapper::class);
        $this->bindValidatable($wrapper, $validatable);
        $this->assertTrue($wrapper->validate($input));
    }