From dc98942d4b15ecdc54da91f2746527c4426d23d3 Mon Sep 17 00:00:00 2001 From: Nathanael Esayeas Date: Sun, 23 Jul 2023 16:03:03 -0500 Subject: [PATCH] Update README.md Signed-off-by: Nathanael Esayeas --- README.md | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 5d4863e..1a0c0d3 100644 --- a/README.md +++ b/README.md @@ -19,16 +19,15 @@ work in progress You can install the package via composer: ``` bash -composer require ghostwriter/psalm-plugin-tester:dev-main +composer require ghostwriter/psalm-plugin-tester --dev ``` ## Usage -- Create a `tests/Fixtures/` directory. +Fork or Clone [`ghostwriter/example-psalm-plugin`](https://github.com/ghostwriter/example-psalm-plugin) template repository. -- Create a test fixture `psalm-runs-without-any-errors` directory in `tests/Fixtures/`. -- Add 1 or more test fixture php files to be checked in `tests/Fixtures/psalm-runs-without-any-errors` directory. +- Create a `tests/Fixture/` directory. - Create a PHPUnit test using the example below. @@ -139,13 +138,13 @@ final class ExamplePluginTest extends TestCase > { > "errors": [ > { -> "file": "code.php" -> "type": "MixedInferredReturnType" +> "file": "code.php", +> "type": "MixedInferredReturnType", > "message": "Providers must return iterable>, possibly different array provided" > }, > { -> "file": "car.php" -> "type": "PossiblyUnusedMethod" +> "file": "car.php", +> "type": "PossiblyUnusedMethod", > "message": "Cannot find any calls to method NS\\Car::drive" > } > ]