Avoid resetting the 'hierarchical' argument in get_pages() when 'parent' is -1, the default.

Fixes a regression introduced in [25270]. Adds unit tests.

props chrisbliss18.
fixes #25750.


git-svn-id: https://develop.svn.wordpress.org/trunk@25974 602fd350-edb4-49c9-b593-d223f7449a82
Move the unit test added in [25974] to the more appropriate file. see #25750.


git-svn-id: https://develop.svn.wordpress.org/trunk@25975 602fd350-edb4-49c9-b593-d223f7449a82