19 lines
608 B
PHP
19 lines
608 B
PHP
<?php
|
|
function assertTrue($cond, $msg) {
|
|
if (!$cond) {
|
|
fwrite(STDERR, $msg . PHP_EOL);
|
|
exit(1);
|
|
}
|
|
}
|
|
|
|
$composer = file_get_contents(__DIR__ . '/../composer.json');
|
|
assertTrue(strpos($composer, 'phpmailer/phpmailer') !== false, 'missing phpmailer dependency');
|
|
|
|
$functions = file_get_contents(__DIR__ . '/../includes/functions.php');
|
|
assertTrue(strpos($functions, 'PHPMailer') !== false, 'missing PHPMailer usage');
|
|
|
|
$config = file_get_contents(__DIR__ . '/../includes/config.php');
|
|
assertTrue(strpos($config, 'MAIL_HOST') !== false, 'missing mail constants');
|
|
|
|
fwrite(STDOUT, "OK\n");
|