File tree Expand file tree Collapse file tree 2 files changed +5
-10
lines changed
app/code/Magento/CatalogRule Expand file tree Collapse file tree 2 files changed +5
-10
lines changed Original file line number Diff line number Diff line change @@ -47,10 +47,11 @@ private function createTemporaryTable(string $originalTableName): string
47
47
$ originalTableName . '__temp ' . $ this ->generateRandomSuffix ()
48
48
);
49
49
50
- $ this ->resourceConnection ->getConnection ()->createTable (
51
- $ this ->resourceConnection ->getConnection ()->createTableByDdl (
52
- $ this ->resourceConnection ->getTableName ($ originalTableName ),
53
- $ temporaryTableName
50
+ $ this ->resourceConnection ->getConnection ()->query (
51
+ sprintf (
52
+ 'create table %s like %s ' ,
53
+ $ temporaryTableName ,
54
+ $ this ->resourceConnection ->getTableName ($ originalTableName )
54
55
)
55
56
);
56
57
Original file line number Diff line number Diff line change @@ -95,12 +95,6 @@ public function testGetWorkingTableNameWithoutExistingTemporaryTable(): void
95
95
->method ('getTableName ' )
96
96
->with ($ this ->stringStartsWith ($ originalTableName . '__temp ' ))
97
97
->willReturn ($ temporaryTableName );
98
- $ this ->adapterInterfaceMock ->expects ($ this ->once ())
99
- ->method ('createTable ' )
100
- ->willReturn ($ this ->statementInterfaceMock );
101
- $ this ->adapterInterfaceMock ->expects ($ this ->once ())
102
- ->method ('createTableByDdl ' )
103
- ->willReturn ($ this ->tableMock );
104
98
105
99
$ this ->assertEquals (
106
100
$ temporaryTableName ,
You can’t perform that action at this time.
0 commit comments