GuzzleHttp\Tests\UriTemplateTest::testAllowsNestedArrayExpansion PHP Method

testAllowsNestedArrayExpansion() public method

    public function testAllowsNestedArrayExpansion()
    {
        $template = new UriTemplate();
        $result = $template->expand('http://example.com{+path}{/segments}{?query,data*,foo*}', array('path' => '/foo/bar', 'segments' => array('one', 'two'), 'query' => 'test', 'data' => array('more' => array('fun', 'ice cream')), 'foo' => array('baz' => array('bar' => 'fizz', 'test' => 'buzz'), 'bam' => 'boo')));
        $this->assertEquals('http://example.com/foo/bar/one,two?query=test&more%5B0%5D=fun&more%5B1%5D=ice%20cream&baz%5Bbar%5D=fizz&baz%5Btest%5D=buzz&bam=boo', $result);
    }