1 system.test | public UuidUnitTestCase::testUuidIsUnique() |
Test that generated UUIDs are unique.
File
- core/
modules/ system/ tests/ system.test, line 2831 - Tests for system.module.
Class
- UuidUnitTestCase
- Tests uuid.inc and related functions.
Code
public function testUuidIsUnique() {
$uuid1 = $this->uuid->generate();
$uuid2 = $this->uuid->generate();
$this->assertNotEqual($uuid1, $uuid2, 'Same UUID was not generated twice.');
}