1<?php
2
3declare(strict_types=1);
4
5namespace JMS\Serializer\Tests\Metadata;
6
7use JMS\Serializer\Metadata\VirtualPropertyMetadata;
8use JMS\Serializer\Tests\Fixtures\ObjectWithVirtualProperties;
9
10class VirtualPropertyMetadataTest extends AbstractPropertyMetadataTest
11{
12    public function testSerialization()
13    {
14        $meta = new VirtualPropertyMetadata(ObjectWithVirtualProperties::class, 'getEmptyValue');
15        $this->setNonDefaultMetadataValues($meta);
16
17        $restoredMeta = unserialize(serialize($meta));
18        $this->assertEquals($meta, $restoredMeta);
19    }
20}
21