Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added PHPUnit as dev dependency, and support versions 5 and 6. #28

Merged
merged 2 commits into from
Nov 13, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ install:
- composer install --prefer-source --no-interaction

script:
- phpunit --coverage-text
- vendor/bin/phpunit --coverage-text
20 changes: 18 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ generate structured (configuration) files on the fly.
* [processTemplate()](#processtemplate)
* [processDefinition()](#processdefinition)
* [Install](#install)
* [Tests](#tests)
* [License](#license)

## Input data
Expand Down Expand Up @@ -200,7 +201,7 @@ If you want to see the usage help,
simply invoke its help by calling like this:

```bash
$ confgen
$ confgen
```

If you have installed this via `$ composer require`, then you may have to
Expand Down Expand Up @@ -269,7 +270,7 @@ generate a output (configuration) file from the given [template file](#templates
$confgen->processTemplate('template.twig', 'data.json');
```

See also [templates section](#templates) above for more details on the
See also [templates section](#templates) above for more details on the
The [input data](#input-data).

#### processDefinition
Expand All @@ -295,6 +296,21 @@ The recommended way to install this library is [through composer](http://getcomp
}
```

## Tests

To run the test suite, you first need to clone this repo and then install all
dependencies [through Composer](http://getcomposer.org):

```bash
$ composer install
```

To run the test suite, go to the project root and run:

```bash
$ php vendor/bin/phpunit
```

## License

MIT
3 changes: 3 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,8 @@
"twig/twig": "~1.14",
"kzykhys/yaml-front-matter": "~1.0",
"justinrainbow/json-schema": "~1.4"
},
"require-dev": {
"phpunit/phpunit": "~4.8.35 || ~5.7 || ~6.4"
}
}
4 changes: 3 additions & 1 deletion tests/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@

require __DIR__ . '/../vendor/autoload.php';

class TestCase extends PHPUnit_Framework_TestCase
use PHPUnit\Framework\TestCase as BaseTestCase;

class TestCase extends BaseTestCase
{

}