mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-02-16 06:51:27 +00:00
Create readme
This commit is contained in:
parent
a5241d9078
commit
0cff61e7e7
43
README.md
43
README.md
@ -1,16 +1,17 @@
|
|||||||
<p align="center">
|
<p align="center">
|
||||||
<img src="https://avatars.githubusercontent.com/u/5228734?s=280&v=4" alt="NFQ Group"/>
|
<img src="https://avatars.githubusercontent.com/u/5228734?s=280&v=4" alt="NFQ Group"/>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
# GildedRose Kata - PHP Version
|
# GildedRose Kata - PHP Version
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
The kata uses:
|
##### The kata uses:
|
||||||
|
|
||||||
- [8.0+](https://www.php.net/downloads.php)
|
- [8.0+](https://www.php.net/downloads.php)
|
||||||
- [Composer](https://getcomposer.org)
|
- [Composer](https://getcomposer.org)
|
||||||
|
|
||||||
Recommended:
|
##### Recommended:
|
||||||
|
|
||||||
- [Git](https://git-scm.com/downloads)
|
- [Git](https://git-scm.com/downloads)
|
||||||
|
|
||||||
@ -27,17 +28,17 @@ or
|
|||||||
git clone https://github.com/thang-tran-nfq/GildedRose-Refactoring-Kata.git
|
git clone https://github.com/thang-tran-nfq/GildedRose-Refactoring-Kata.git
|
||||||
```
|
```
|
||||||
|
|
||||||
Setup docker-compose
|
##### Setup docker-compose
|
||||||
```shell script
|
```shell script
|
||||||
docker-compose up -d
|
docker-compose up -d
|
||||||
```
|
```
|
||||||
|
|
||||||
Exec the docker container
|
##### Exec the docker container
|
||||||
```shell script
|
```shell script
|
||||||
docker exec -it php-cli bash
|
docker exec -it php-cli bash
|
||||||
```
|
```
|
||||||
|
|
||||||
Install all the dependencies using composer
|
##### Install all the dependencies using composer
|
||||||
|
|
||||||
```shell script
|
```shell script
|
||||||
cd ./GildedRose-Refactoring-Kata
|
cd ./GildedRose-Refactoring-Kata
|
||||||
@ -46,7 +47,7 @@ composer install
|
|||||||
|
|
||||||
## Dependencies
|
## Dependencies
|
||||||
|
|
||||||
The project uses composer to install:
|
##### The project uses composer to install:
|
||||||
|
|
||||||
- [PHPUnit](https://phpunit.de/)
|
- [PHPUnit](https://phpunit.de/)
|
||||||
- [ApprovalTests.PHP](https://github.com/approvals/ApprovalTests.php)
|
- [ApprovalTests.PHP](https://github.com/approvals/ApprovalTests.php)
|
||||||
@ -77,7 +78,7 @@ The project uses composer to install:
|
|||||||
|
|
||||||
## Fixture
|
## Fixture
|
||||||
|
|
||||||
To run the fixture from the php directory:
|
##### To run the fixture from the php directory:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
php .\fixtures\texttest_fixture.php 10
|
php .\fixtures\texttest_fixture.php 10
|
||||||
@ -94,13 +95,6 @@ project run:
|
|||||||
composer tests
|
composer tests
|
||||||
```
|
```
|
||||||
|
|
||||||
A Windows a batch file has been created, like an alias on Linux/Mac (e.g. `alias pu="composer tests"`), the same
|
|
||||||
PHPUnit `composer tests` can be run:
|
|
||||||
|
|
||||||
```shell script
|
|
||||||
pu.bat
|
|
||||||
```
|
|
||||||
|
|
||||||
### Tests with Coverage Report
|
### Tests with Coverage Report
|
||||||
|
|
||||||
To run all test and generate a html coverage report run:
|
To run all test and generate a html coverage report run:
|
||||||
@ -127,13 +121,6 @@ To check code, but not fix errors:
|
|||||||
composer check-cs
|
composer check-cs
|
||||||
```
|
```
|
||||||
|
|
||||||
On Windows a batch file has been created, like an alias on Linux/Mac (e.g. `alias cc="composer check-cs"`), the same
|
|
||||||
PHPUnit `composer check-cs` can be run:
|
|
||||||
|
|
||||||
```shell script
|
|
||||||
cc.bat
|
|
||||||
```
|
|
||||||
|
|
||||||
### Fix Code
|
### Fix Code
|
||||||
|
|
||||||
ECS provides may code fixes, automatically, if advised to run --fix, the following script can be run:
|
ECS provides may code fixes, automatically, if advised to run --fix, the following script can be run:
|
||||||
@ -142,13 +129,6 @@ ECS provides may code fixes, automatically, if advised to run --fix, the followi
|
|||||||
composer fix-cs
|
composer fix-cs
|
||||||
```
|
```
|
||||||
|
|
||||||
On Windows a batch file has been created, like an alias on Linux/Mac (e.g. `alias fc="composer fix-cs"`), the same
|
|
||||||
PHPUnit `composer fix-cs` can be run:
|
|
||||||
|
|
||||||
```shell script
|
|
||||||
fc.bat
|
|
||||||
```
|
|
||||||
|
|
||||||
## Static Analysis
|
## Static Analysis
|
||||||
|
|
||||||
PHPStan is used to run static analysis checks:
|
PHPStan is used to run static analysis checks:
|
||||||
@ -157,11 +137,4 @@ PHPStan is used to run static analysis checks:
|
|||||||
composer phpstan
|
composer phpstan
|
||||||
```
|
```
|
||||||
|
|
||||||
On Windows a batch file has been created, like an alias on Linux/Mac (e.g. `alias ps="composer phpstan"`), the same
|
|
||||||
PHPUnit `composer phpstan` can be run:
|
|
||||||
|
|
||||||
```shell script
|
|
||||||
ps.bat
|
|
||||||
```
|
|
||||||
|
|
||||||
**Happy coding**!
|
**Happy coding**!
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user