diff --git a/tests/WP_SQLite_Driver_Metadata_Tests.php b/tests/WP_SQLite_Driver_Metadata_Tests.php index 90cddb7f..67f7ad76 100644 --- a/tests/WP_SQLite_Driver_Metadata_Tests.php +++ b/tests/WP_SQLite_Driver_Metadata_Tests.php @@ -1319,6 +1319,7 @@ public function testInformationSchemaForeignKeys(): void { $this->assertEquals( array( (object) array( + 'Table' => 't2', 'Create Table' => implode( "\n", array( @@ -1451,6 +1452,7 @@ public function testInformationSchemaInlineForeignKeys(): void { $this->assertEquals( array( (object) array( + 'Table' => 't2', 'Create Table' => implode( "\n", array( @@ -1558,6 +1560,7 @@ public function testInformationSchemaForeignKeysWithMultipleColumns(): void { $this->assertEquals( array( (object) array( + 'Table' => 't2', 'Create Table' => implode( "\n", array( @@ -1681,6 +1684,7 @@ public function testInformationSchemaAlterTableAddForeignKeys(): void { $this->assertEquals( array( (object) array( + 'Table' => 't2', 'Create Table' => implode( "\n", array( @@ -1725,6 +1729,7 @@ public function testInformationSchemaAlterTableDropForeignKeys(): void { $this->assertEquals( array( (object) array( + 'Table' => 't2', 'Create Table' => implode( "\n", array( @@ -1764,6 +1769,7 @@ public function testInformationSchemaAlterTableDropForeignKeys(): void { $this->assertEquals( array( (object) array( + 'Table' => 't2', 'Create Table' => implode( "\n", array( @@ -1799,6 +1805,7 @@ public function testInformationSchemaAlterTableDropForeignKeys(): void { $this->assertEquals( array( (object) array( + 'Table' => 't2', 'Create Table' => implode( "\n", array( @@ -1830,6 +1837,7 @@ public function testInformationSchemaAlterTableDropForeignKeys(): void { $this->assertEquals( array( (object) array( + 'Table' => 't2', 'Create Table' => implode( "\n", array( @@ -1852,6 +1860,7 @@ public function testInformationSchemaAlterTableDropPrimaryKey(): void { $this->assertEquals( array( (object) array( + 'Table' => 't', 'Create Table' => implode( "\n", array( @@ -1882,6 +1891,7 @@ public function testInformationSchemaAlterTableDropPrimaryKey(): void { $this->assertEquals( array( (object) array( + 'Table' => 't', 'Create Table' => implode( "\n", array( @@ -1913,6 +1923,7 @@ public function testInformationSchemaAlterTableDropUniqueKey(): void { $this->assertEquals( array( (object) array( + 'Table' => 't', 'Create Table' => implode( "\n", array( diff --git a/tests/WP_SQLite_Driver_Tests.php b/tests/WP_SQLite_Driver_Tests.php index 542c5ea2..1176ea69 100644 --- a/tests/WP_SQLite_Driver_Tests.php +++ b/tests/WP_SQLite_Driver_Tests.php @@ -9664,6 +9664,7 @@ public function testFullyQualifiedTableName(): void { $this->assertEquals( array( (object) array( + 'Table' => 't', 'Create Table' => implode( "\n", array( diff --git a/wp-includes/sqlite-ast/class-wp-sqlite-driver.php b/wp-includes/sqlite-ast/class-wp-sqlite-driver.php index 3a9c13e6..0137a6b9 100644 --- a/wp-includes/sqlite-ast/class-wp-sqlite-driver.php +++ b/wp-includes/sqlite-ast/class-wp-sqlite-driver.php @@ -2263,6 +2263,7 @@ private function execute_show_statement( WP_Parser_Node $node ): void { $this->set_results_from_fetched_data( array( (object) array( + 'Table' => $table_name, 'Create Table' => $sql, ), )