Skip to content

Commit

Permalink
Clean-up some conflicts introduced in my prev commit.
Browse files Browse the repository at this point in the history
  • Loading branch information
stronk7 committed Aug 30, 2009
1 parent f78c210 commit c6ea7fc
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions lib/ddl/simpletest/testddl.php
Original file line number Diff line number Diff line change
Expand Up @@ -1251,12 +1251,12 @@ public function test_temp_tables() {
$DB = $this->tdb; // do not use global $DB!
$dbman = $this->tdb->get_manager();

// Create temp table
// Create temp table0
$table0 = $this->tables['test_table0'];
$dbman->create_temp_table($table0);
$this->assertTrue($dbman->table_exists('test_table0', true));

// Create another temp table
// Create another temp table1
$table1 = $this->tables['test_table1'];
$dbman->create_temp_table($table1);
$this->assertTrue($dbman->table_exists('test_table1'));
Expand All @@ -1277,9 +1277,18 @@ public function test_temp_tables() {
$this->assertEqual($records[1]->secondname, $this->records['test_table1'][0]->secondname);
$this->assertEqual($records[2]->intro, $this->records['test_table1'][1]->intro);

// Drop table
// Drop table1
$dbman->drop_temp_table($table1);
$this->assertFalse($dbman->table_exists('test_table1'));

// Fill/modify/delete a few table0 records
// TODO: that's

// Drop table0
$dbman->drop_temp_table($table0);
$this->assertFalse($dbman->table_exists('test_table0'));

// Have dropped all these temp tables here, to avoid conflicts with other (normal tables) tests!
}

public function test_reset_sequence() {
Expand Down

0 comments on commit c6ea7fc

Please sign in to comment.