|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
/* |
|
4
|
|
|
* This file is part of the Bukashk0zzzYmlGenerator |
|
5
|
|
|
* |
|
6
|
|
|
* (c) Denis Golubovskiy <[email protected]> |
|
7
|
|
|
* |
|
8
|
|
|
* For the full copyright and license information, please view the LICENSE |
|
9
|
|
|
* file that was distributed with this source code. |
|
10
|
|
|
*/ |
|
11
|
|
|
|
|
12
|
|
|
namespace Bukashk0zzz\YmlGenerator\Tests; |
|
13
|
|
|
|
|
14
|
|
|
use Bukashk0zzz\YmlGenerator\Model\Offer\OfferAudiobook; |
|
15
|
|
|
|
|
16
|
|
|
/** |
|
17
|
|
|
* Generator test |
|
18
|
|
|
*/ |
|
19
|
|
|
class OfferAudiobookGeneratorTest extends AbstractGeneratorTest |
|
20
|
|
|
{ |
|
21
|
|
|
/** |
|
22
|
|
|
* Test generate |
|
23
|
|
|
*/ |
|
24
|
|
|
public function testGenerate() |
|
25
|
|
|
{ |
|
26
|
|
|
$this->offerType = 'Audiobook'; |
|
27
|
|
|
$this->runGeneratorTest(); |
|
28
|
|
|
} |
|
29
|
|
|
|
|
30
|
|
|
/** |
|
31
|
|
|
* {@inheritdoc} |
|
32
|
|
|
*/ |
|
33
|
|
|
protected function createOffer() |
|
34
|
|
|
{ |
|
35
|
|
|
return (new OfferAudiobook()) |
|
36
|
|
|
->setAuthor($this->faker->name) |
|
37
|
|
|
->setName($this->faker->name) |
|
38
|
|
|
->setPublisher($this->faker->name) |
|
39
|
|
|
->setSeries($this->faker->name) |
|
40
|
|
|
->setYear($this->faker->numberBetween(1, 9999)) |
|
41
|
|
|
->setISBN($this->faker->isbn13) |
|
42
|
|
|
->setVolume($this->faker->numberBetween(1, 9999)) |
|
43
|
|
|
->setPart($this->faker->numberBetween(1, 9999)) |
|
44
|
|
|
->setLanguage($this->faker->name) |
|
45
|
|
|
->setTableOfContents($this->faker->name) |
|
46
|
|
|
->setPerformedBy($this->faker->name) |
|
47
|
|
|
->setPerformanceType($this->faker->name) |
|
48
|
|
|
->setStorage($this->faker->name) |
|
49
|
|
|
->setFormat($this->faker->name) |
|
50
|
|
|
->setRecordingLength($this->faker->name) |
|
51
|
|
|
; |
|
52
|
|
|
} |
|
53
|
|
|
} |
|
54
|
|
|
|