From 8343b340c4ef2ca55c1d76cde7fc125cdd188ab2 Mon Sep 17 00:00:00 2001 From: Russell Smith Date: Wed, 26 Jun 2013 20:37:42 +1000 Subject: [PATCH] MDL-39725 database: Include stats collections in unit tests --- lib/ddl/tests/ddl_test.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/ddl/tests/ddl_test.php b/lib/ddl/tests/ddl_test.php index 7644a2319a1..d5e63a9fa3f 100644 --- a/lib/ddl/tests/ddl_test.php +++ b/lib/ddl/tests/ddl_test.php @@ -1545,6 +1545,9 @@ class core_ddl_testcase extends database_driver_testcase { $this->assertSame($records[1]->secondname, $this->records['test_table1'][0]->secondname); $this->assertSame($records[2]->intro, $this->records['test_table1'][1]->intro); + // Collect statistics about the data in the temp table. + $DB->update_temp_table_stats(); + // Drop table1. $dbman->drop_table($table1); $this->assertFalse($dbman->table_exists('test_table1')); @@ -1558,6 +1561,9 @@ class core_ddl_testcase extends database_driver_testcase { $this->assertInstanceOf('ddl_table_missing_exception', $e); } + // Collect statistics about the data in the temp table with less tables. + $DB->update_temp_table_stats(); + // Fill/modify/delete a few table0 records. // Drop table0.