public function testVersionedRecordDoesNotHaveAutoIncrement() { $tvm = new TestVersionedModel(); $util = new DatabaseLayer\Util(); $keys = $util->getIndexes($tvm->getDatabaseTable()); $failed = false; foreach ($keys as $key) { if ($key->Auto_increment) { $failed = true; } } $this->assertFalse($failed, "One of the keys for a Versioned record is autoincrementing."); }
public function getTableIndexes($table_name) { $util = new DatabaseLayer\Util(); $indexes = $util->getIndexes($table_name); return $indexes; }