Esempio n. 1
0
 function test_populated_listing()
 {
     $p = $this->factory->post->create(array('post_title' => 'Test Page', 'post_type' => 'page'));
     $q = new WP_Query(array('post_type' => 'page'));
     $expected = sprintf(file_get_contents('tests/populated-listing.txt'), $p);
     $actual = get_the_a_z_listing($q);
     $expected = preg_replace('/\\s{2,}|\\t|\\n/', '', $expected);
     $actual = preg_replace('/\\s{2,}|\\t|\\n/', '', $actual);
     $this->assertEquals($expected, $actual);
 }
Esempio n. 2
0
/**
 * @deprecated in favour of get_the_a_z_listing()
 */
function get_the_az_listing($query = null, $colcount = 1, $minpercol = 10, $h = 2)
{
    return get_the_a_z_listing($query, $colcount, $minpercol, $h);
}