/**
  * @param array $entities
  *
  * @Then /^I should not see products? (.*)$/
  * @Then /^I should not see attributes? (?!(.*)in group )(.*)$/
  * @Then /^I should not see channels? (.*)$/
  * @Then /^I should not see locales? (.*)$/
  * @Then /^I should not see (?:import|export) profiles? (.*)$/
  * @Then /^I should not see (?:(?:entit|currenc)(?:y|ies)) (.*)$/
  * @Then /^I should not see group(?: type)?s? (.*)$/
  * @Then /^I should not see association (?:types? )?(.*)$/
  * @Then /^I should not see famil(?:y|ies) (.*)$/
  */
 public function iShouldNotSeeEntities($entities)
 {
     if ($this->datagrid->isGridEmpty()) {
         return;
     }
     foreach ($this->getMainContext()->listToArray($entities) as $entity) {
         if ($this->datagrid->hasRow($entity)) {
             throw $this->createExpectationException(sprintf('Entity "%s" should not be seen', $entity));
         }
     }
 }
예제 #2
0
 /**
  * @param array $entities
  *
  * @throws ExpectationException
  *
  * @Then /^I should not see products? (.*)$/
  * @Then /^I should not see attributes? (?!(.*)in group )(.*)$/
  * @Then /^I should not see channels? (.*)$/
  * @Then /^I should not see locales? (.*)$/
  * @Then /^I should not see (?:import|export) profiles? (.*)$/
  * @Then /^I should not see (?:(?:entit|currenc)(?:y|ies)) (.*)$/
  * @Then /^I should not see group(?: type)?s? (.*)$/
  * @Then /^I should not see association (?:types? )?(.*)$/
  * @Then /^I should not see famil(?:y|ies) (.*)$/
  */
 public function iShouldNotSeeEntities($entities)
 {
     $entitiesArray = $this->getMainContext()->listToArray($entities);
     $this->spin(function () use($entitiesArray) {
         if ($this->datagrid->isGridEmpty()) {
             return true;
         }
         foreach ($entitiesArray as $entity) {
             if ($this->datagrid->hasRow($entity)) {
                 return false;
             }
         }
         return true;
     }, sprintf('Expected not to see "%s"', $entities));
 }