Simple placeholders should not be quoted
This commit is contained in:
parent
9c33f133b6
commit
bf0da0287d
|
@ -82,7 +82,7 @@ class WC_Tests_Product_Data extends WC_Unit_Test_Case {
|
|||
$this->assertEquals( $product->get_date_on_sale_to()->getTimestamp(), 1477267200 );
|
||||
|
||||
$image_url = media_sideload_image( 'https://cldup.com/Dr1Bczxq4q.png', $product->get_id(), '', 'src' );
|
||||
$image_id = $wpdb->get_col( $wpdb->prepare( "SELECT ID FROM {$wpdb->posts} WHERE guid='%s';", $image_url ) );
|
||||
$image_id = $wpdb->get_col( $wpdb->prepare( "SELECT ID FROM {$wpdb->posts} WHERE guid = %s", $image_url ) );
|
||||
$product->set_image_id( $image_id[0] );
|
||||
$product->save();
|
||||
$this->assertEquals( $image_id[0], $product->get_image_id() );
|
||||
|
|
Loading…
Reference in New Issue