本文整理汇总了PHP中ApiTester::assertFalse方法的典型用法代码示例。如果您正苦于以下问题:PHP ApiTester::assertFalse方法的具体用法?PHP ApiTester::assertFalse怎么用?PHP ApiTester::assertFalse使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ApiTester
的用法示例。
在下文中一共展示了ApiTester::assertFalse方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: read
/**
* Preberem zapis in preverim vsa polja
*
* @depends create
* @param ApiTester $I
*/
public function read(\ApiTester $I)
{
$ent = $I->successfullyGet($this->restUrl, $this->obj['id']);
codecept_debug($ent);
$I->assertNotEmpty($ent['id']);
$I->assertEquals($ent['sifra'], '99');
$I->assertEquals($ent['naziv'], 'B');
$I->assertEquals($ent['vodja'], $this->objZaposlitev1['id']);
$I->assertEquals($ent['namestnik'], $this->objZaposlitev2['id']);
$I->assertFalse(isset($ent['parent']));
}
示例2: removeTokens
public function removeTokens(ApiTester $I)
{
$user = $I->createUser();
$I->getMongo();
$tokens = ['reset_password' => ["token" => '$2y$10$iiPJClTgDWOgP0SR1ZgwLeMO4qNZkGFXHRjRpkyl.xC2K6OLPxExK', "expired" => time() + 30], 'verify_email' => ["token" => '$3y$10$iiPJClTgDWOgP0SR1ZgwLeMO4qNZkGFXHRjRpkyl.xC1K6OLPxExK', "expired" => time() - 1]];
$filter = ['_id' => new MongoDB\BSON\ObjectID($user->_id)];
$bulk = new MongoDB\Driver\BulkWrite();
$bulk->update($filter, ['$set' => ['tokens' => $tokens, 'refreshTokens.0.expires' => time() - 1]]);
$I->getMongo()->executeBulkWrite('gandalf_test.users', $bulk);
exec('php artisan tokens:delete');
$query = new MongoDB\Driver\Query($filter);
$rows = $I->getMongo()->executeQuery('gandalf_test.users', $query);
$user = $rows->toArray()[0];
$I->assertFalse(property_exists($user->tokens, 'verify_email'), 'Expired verify_email token don\'t deleted');
$I->assertEquals(0, count($user->refreshTokens), 'Expired refresh token do not deleted');
}
示例3: read
/**
* Preberem zapis in preverim vsa polja
*
* @depends create
* @param ApiTester $I
*/
public function read(\ApiTester $I)
{
$ent = $I->successfullyGet($this->restUrl, $this->obj['id']);
codecept_debug($ent);
$I->assertNotEmpty($ent['id']);
$I->assertEquals($ent['faza'], 'produkcija');
$I->assertEquals($ent['naslov'], 'zz');
$I->assertEquals($ent['podnaslov'], 'zz');
$I->assertEquals($ent['delovniNaslov'], 'zz');
$I->assertEquals($ent['datumZacStudija'], '2011-02-01T00:00:00+0100');
$I->assertEquals($ent['datumPremiere'], '2012-02-01T00:00:00+0100');
$I->assertEquals($ent['maticniOder'], $this->lookProstor['id']);
$I->assertEquals($ent['stOdmorov'], 1);
// $I->assertEquals($ent['avtor'], 'avzz');
$I->assertEquals($ent['gostujoca'], FALSE);
$I->assertEquals($ent['trajanje'], 2);
$I->assertEquals($ent['opis'], 'yy');
$I->assertEquals($ent['arhIdent'], 'zz');
$I->assertEquals($ent['arhOpomba'], 'zz');
$I->assertEquals($ent['datumZakljucka'], '2019-02-01T00:00:00+0100');
$I->assertEquals($ent['sloAvtor'], FALSE);
$I->assertEquals($ent['jeKoprodukcija'], FALSE);
$I->assertEquals($ent['kratkiNaslov'], 'zz');
$I->assertEquals($ent['besedilo']['id'], $this->lookBesedilo['id'], "Besedilo");
$I->assertEquals($ent['zvrstUprizoritve'], null);
$I->assertEquals($ent['zvrstSurs'], $this->lookZvrstSurs['id']);
$I->assertEquals($ent['internacionalniNaslov'], 'zz');
// $I->assertEquals($ent['steviloVaj'], 4,"Število vaj");
$I->assertEquals($ent['planiranoSteviloVaj'], 5);
$I->assertEquals($ent['krstna'], true, "krstna");
$I->assertEquals($ent['prvaSlovenska'], true);
$I->assertEquals($ent['naslovIzvirnika'], 'zz');
$I->assertEquals($ent['podnaslovIzvirnika'], 'zz');
$I->assertFalse(isset($ent['producent']), "producent");
$I->assertTrue(isset($ent['funkcije']));
$I->assertTrue(isset($ent['arhivi']));
$I->assertTrue(isset($ent['rekviziterstva']));
$I->assertTrue(isset($ent['vaje']));
$I->assertTrue(isset($ent['predstave']));
// $I->assertTrue(isset($ent['gostujoce']));
$I->assertEquals(0, count($ent['funkcije']));
$I->assertEquals(0, count($ent['arhivi']));
$I->assertEquals(0, count($ent['rekviziterstva']));
$I->assertEquals(0, count($ent['vaje']));
$I->assertEquals(0, count($ent['predstave']));
// $I->assertEquals(0, count($ent['gostujoce']));
}