src/Codeception/Module/WPDb.php
public function seeTermInDatabase(array $criteria)
    {
        $termsCriteria = array_intersect_key($criteria, array_flip($this->termKeys));
        $termTaxonomyCriteria = array_intersect_key($criteria, array_flip($this->termTaxonomyKeys));

        if (!empty($termsCriteria)) {
            // this one fails... go to...
            $this->seeInDatabase($this->grabTermsTableName(), $termsCriteria);
        }
        if (!empty($termTaxonomyCriteria)) {
            $this->seeInDatabase($this->grabTermTaxonomyTableName(), $termTaxonomyCriteria);
        }
    }
public function seeTermInDatabase(array $criteria)
    {
        $termsCriteria = array_intersect_key($criteria, array_flip($this->termKeys));
        $termTaxonomyCriteria = array_intersect_key($criteria, array_flip($this->termTaxonomyKeys));

        if (!empty($termsCriteria)) {
            // this one fails... go to...
            $this->seeInDatabase($this->grabTermsTableName(), $termsCriteria);
        }
        if (!empty($termTaxonomyCriteria)) {
            $this->seeInDatabase($this->grabTermTaxonomyTableName(), $termTaxonomyCriteria);
        }
    }
public function seeTermInDatabase ( array $ criteria ) { $ termsCriteria = array_intersect_key ( $ criteria , array_flip ( $ this -> termKeys ) ) ; $ termTaxonomyCriteria = array_intersect_key ( $ criteria , array_flip ( $ this -> termTaxonomyKeys ) ) ; if ( ! empty ( $ termsCriteria ) ) { // this one fails... go to... $ this -> seeInDatabase ( $ this -> grabTermsTableName ( ) , $ termsCriteria ) ; } if ( ! empty ( $ termTaxonomyCriteria ) ) { $ this -> seeInDatabase ( $ this -> grabTermTaxonomyTableName ( ) , $ termTaxonomyCriteria ) ; } }
Checks for a term in the database.
Looks up the `terms` and `term_taxonomy` prefixed tables.

@example
```php
$I->seeTermInDatabase(['slug' => 'genre--fiction']);
$I->seeTermInDatabase(['name' => 'Fiction', 'slug' => 'genre--fiction']);
```

@param array $criteria An array of criteria to search for the term, can be columns from the `terms` and the
`term_taxonomy` tables.
Checks for a term in the database . Looks up the terms and term_taxonomy prefixed tables .