public function testCopy()
{
$snippet = $this->snippetFromMethod(StorageObject::class, 'copy');
$snippet->addLocal('object', $this->object);
$this->connection->copyObject(Argument::any())->shouldBeCalled()->willReturn(['name' => 'New Object', 'bucket' => self::BUCKET, 'generation' => 'foo']);
$this->object->setConnection($this->connection->reveal());
$res = $snippet->invoke('copiedObject');
$this->assertInstanceOf(StorageObject::class, $res->returnVal());
}