Set the default parent id to 0, instead of -1, in `Tests_Post_Attachments::_make_attachment()`. Prevents `Out of range value for column 'post_parent'` database error without papering over it in core.

See #25282.



git-svn-id: https://develop.svn.wordpress.org/trunk@26004 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Scott Taylor 2013-11-04 21:39:35 +00:00
parent e512f03e75
commit ecbcfc5a20
1 changed files with 1 additions and 1 deletions

View File

@ -16,7 +16,7 @@ class Tests_Post_Attachments extends WP_UnitTestCase {
parent::tearDown();
}
function _make_attachment($upload, $parent_post_id=-1) {
function _make_attachment( $upload, $parent_post_id = 0 ) {
$type = '';
if ( !empty($upload['type']) ) {