Test spambot_report_account() function with incorrect "api_key".

Fichier

tests/src/Kernel/SpambotUserspamTest.php, line 54

Classe

SpambotUserspamTest
Test spambot report account.

Namespace

Drupal\Tests\spambot\Kernel

Code

public function testSpambotReportAccountIncorrectApiKey() {
    $key = 'notExist503';
    $success = spambot_report_account($this->user, '130.176.13.140', 'title', $key);
    $this->assertFalse($success, 'Field api key should not be filled.');
}