easyappointments/tests/Unit/Helper/ValidationHelperTest.php

18 lines
391 B
PHP
Raw Permalink Normal View History

2023-03-23 10:05:08 +03:00
<?php
namespace Tests\Unit\Helper;
2023-03-23 10:05:08 +03:00
use Tests\TestCase;
2023-03-23 10:05:08 +03:00
class ValidationHelperTest extends TestCase {
public function testValidateDateTimeReturnsTrueOnValidValue()
{
$this->assertTrue(validate_datetime(date('Y-m-d H:i:s')));
}
public function testValidateDateTimeReturnsFalseOnInvalidValue()
{
$this->assertFalse(validate_datetime('invalid'));
}
}