Skip to content

Commit 0709ebb

Browse files
committed
Fixing composer json
1 parent 02cfcac commit 0709ebb

File tree

4 files changed

+10
-5
lines changed

4 files changed

+10
-5
lines changed

composer.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"php": "^7.2",
1414
"ext-dom": "*",
1515
"ext-libxml": "*",
16-
"ext-json": "*"
16+
"ext-json": "*",
1717

1818
"thecodingmachine/safe": "^0.1.16",
1919
"nikic/php-parser": "^4.2",
@@ -37,5 +37,11 @@
3737
"spec\\": "spec/"
3838
}
3939
},
40+
"scripts": {
41+
"analyse": [
42+
"vendor/bin/phpspec run",
43+
"vendor/bin/phpstan analyse"
44+
]
45+
},
4046
"bin": [ "bin/doc-parser" ]
4147
}

spec/Mamazu/DocumentationParser/Validator/ValidatorAggregatorSpec.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,12 @@ public function it_delegates_the_validation(
3030
ValidatorInterface $validator1,
3131
ValidatorInterface $validator2,
3232
Block $block
33-
) {
33+
): void {
3434
$block->getType()->willReturn('php');
3535

3636
$this->beConstructedWith(['php' => $validator1, 'python' => $validator2]);
3737

38-
$validator1->validate($block)->willReturn([new Error('hello.md', 0, 'Error',)]);
38+
$validator1->validate($block)->willReturn([new Error('hello.md', 0, 'Error')]);
3939
$validator2->validate(Argument::any())->shouldNotBeCalled();
4040

4141
$this->validate($block)->shouldHaveCount(1);

src/Error/Error.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ public function getType(): ?string
5252
return $this->type;
5353
}
5454

55-
public function jsonSerialize()
55+
public function jsonSerialize(): array
5656
{
5757
return [
5858
'fileName' => $this->getFileName(),

tests/test.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ $b = new Block('/tmp','test',1,'txt');
2929
And a little piece of valid yaml:
3030
```yaml
3131
hello:
32-
ll
3332
i_am_groot: true
3433
colors: ['red', 'green', 'blue']
3534
```

0 commit comments

Comments
 (0)