mirror of
https://github.com/elyby/oauth2-server.git
synced 2024-12-23 05:29:52 +05:30
22 lines
608 B
PHP
22 lines
608 B
PHP
<?php
|
|
namespace Codeception\Module;
|
|
|
|
// here you can define custom actions
|
|
// all public methods declared in helper class will be available in $I
|
|
|
|
class AuthHelper extends \Codeception\Module
|
|
{
|
|
function seeJsonKeyExists($key)
|
|
{
|
|
$json = $this->getModule('REST')->grabResponse();
|
|
$array = json_decode($json);
|
|
$this->assertTrue(array_key_exists($key, $array));
|
|
}
|
|
|
|
function seeJsonKeyDoesNotExists($key)
|
|
{
|
|
$json = $this->getModule('REST')->grabResponse();
|
|
$array = json_decode($json);
|
|
$this->assertFalse(array_key_exists($key, $array));
|
|
}
|
|
} |