public function testSetStatus()
{
$gateway = $this->getDatabaseGateway();
// insert content
$struct = $this->getCreateStructFixture();
$contentId = $gateway->insertContentObject($struct);
// insert version
$version = $this->getVersionFixture();
$version->contentInfo->id = $contentId;
$gateway->insertVersion($version, array());
$this->assertTrue($gateway->setStatus($version->contentInfo->id, $version->versionNo, VersionInfo::STATUS_PENDING));
$this->assertQueryResult(array(array(VersionInfo::STATUS_PENDING)), $this->getDatabaseHandler()->createSelectQuery()->select('status')->from('ezcontentobject_version'));
// check that content status has not been set to published
$this->assertQueryResult(array(array(VersionInfo::STATUS_DRAFT)), $this->getDatabaseHandler()->createSelectQuery()->select('status')->from('ezcontentobject'));
}