|
11 | 11 | $this->assertInstanceOf(Collection::class, $objects); |
12 | 12 | $this->assertTrue($objects->count() > 0); |
13 | 13 | Event::assertDispatched(ZammadResponseLog::class, 1); |
14 | | -})->group('objects'); |
| 14 | +})->group('objects', 'list-objects'); |
15 | 15 |
|
16 | 16 | it('shows a object', function () { |
17 | 17 | $objects = (new Zammad())->object()->list(); |
|
21 | 21 | $newObject = (new Zammad())->object()->show($object->id); |
22 | 22 | $this->assertSame($object->id, $newObject->id); |
23 | 23 | Event::assertDispatched(ZammadResponseLog::class, 2); |
24 | | -})->group('objects'); |
| 24 | +})->group('objects', 'show-object'); |
25 | 25 |
|
26 | 26 | it('creates a object', function () { |
27 | 27 | $objectAttribute = ObjectAttribute::fakeCreateToArray(); |
28 | 28 | $object = (new Zammad())->object()->create($objectAttribute); |
| 29 | + |
29 | 30 | $this->assertInstanceOf(ObjectAttribute::class, $object); |
30 | 31 | $this->assertSame($objectAttribute['name'], $object->name); |
31 | 32 | $this->assertSame($objectAttribute['display'], $object->display); |
32 | 33 | Event::assertDispatched(ZammadResponseLog::class, 1); |
33 | | -})->group('objects'); |
| 34 | + |
| 35 | + (new Zammad())->object()->delete($object->id); |
| 36 | + (new Zammad())->object()->executeMigrations(); |
| 37 | + |
| 38 | +})->group('objects', 'create-object'); |
34 | 39 |
|
35 | 40 | it('update a object', function () { |
36 | 41 | $objectAttribute = ObjectAttribute::fakeCreateToArray(); |
|
62 | 67 | Event::assertDispatched(ZammadResponseLog::class, 2); |
63 | 68 | expect($updatedObjectAttribute['display'])->toEqual($object->display); |
64 | 69 | expect($objectAttribute['display'])->not()->toEqual($object->display); |
65 | | -})->group('objects'); |
| 70 | + |
| 71 | + (new Zammad())->object()->delete($object->id); |
| 72 | + (new Zammad())->object()->executeMigrations(); |
| 73 | + |
| 74 | +})->group('objects', 'update-object'); |
66 | 75 |
|
67 | 76 | it('deletes a object', function () { |
68 | 77 | $objectAttribute = ObjectAttribute::fakeCreateToArray(); |
|
0 commit comments