/** * @group unit * @dataProvider dataProviderCreateInvalid * @expectedException \Elastica\Exception\InvalidException */ public function testCreateInvalid($data) { Script::create($data); }
/** * Sets script object. * * @param \Elastica\Script\Script|string|array $script * * @return $this */ public function setScript($script) { return $this->setParam('script', Elastica\Script\Script::create($script)); }