public function testPath()
{
$snippet = $this->snippetFromMethod(Key::class, 'path');
$snippet->addLocal('key', $this->key);
$this->key->pathElement('Foo', 'Bar');
$res = $snippet->invoke('path');
$this->assertEquals([['kind' => 'Foo', 'name' => 'Bar']], $res->returnVal());
}