/** * Main test. */ public function testConstants() { $constants = Schemes::get_constants(); foreach ($constants as $key => $value) { $this->assertTrue(Schemes::get_constant($key) === $value); } }
<?php /* * Created by IntelliJ IDEA. * User: EgaLabs (c) 2015 * Date: 27/05/2015 * Time: 17:38 */ namespace Matura\Tests\URI; use Ignizr\URI\Schemes; describe("Schemes constants", function () { it("should have all constants well defined and available through get_constants method.", function () { $constants = Schemes::get_constants(); foreach ($constants as $key => $value) { expect(Schemes::get_constant($key) === $value)->to->be->ok(); } }); });