/** * Test schema file exists */ public function testGetSchemaFile() { $this->_initConfig(); $this->assertEquals( $this->urnResolver->getRealPath('urn:magento:framework:Validator/etc/validation.xsd'), $this->_config->getSchemaFile() ); $this->assertFileExists($this->_config->getSchemaFile()); }
/** * Test createValidatorBuilder call */ public function testCreateValidator() { $this->_validatorConfig->expects( $this->once() )->method( 'createValidator' )->with( 'test', 'class', [] )->will( $this->returnValue(new \Magento\Framework\Validator()) ); $factory = new \Magento\Framework\Validator\Factory( $this->_objectManager, $this->_config, $this->cache ); $this->assertInstanceOf('Magento\Framework\Validator', $factory->createValidator('test', 'class', [])); }
/** * Test schema file exists */ public function testGetSchemaFile() { $this->_initConfig(); $this->assertFileExists($this->_config->getSchemaFile()); }