https://github.com/php-forge/support
Support library tests for PHP.
https://github.com/php-forge/support
Last synced: 11 months ago
JSON representation
Support library tests for PHP.
- Host: GitHub
- URL: https://github.com/php-forge/support
- Owner: php-forge
- License: mit
- Created: 2023-07-01T17:49:18.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-21T13:08:20.000Z (about 2 years ago)
- Last Synced: 2024-09-24T17:04:06.586Z (over 1 year ago)
- Language: PHP
- Size: 30.3 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
- Code of conduct: .github/CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
Support.
## Installation
The preferred way to install this extension is through [composer](https://getcomposer.org/download/).
Either run
```shell
composer require --prefer-dist php-forge/support
```
or add
```json
"php-forge/support": "^0.1"
```
to the require-dev section of your `composer.json` file.
## Usage
### Equals without line ending
```php
assertSame('bar', Assert::inaccessibleProperty($object, 'foo'));
```
### Invoke method
```php
assertSame('foo', Assert::invokeMethod($object, 'foo'));
```
### Set inaccessible property
```php
assertSame('baz', Assert::inaccessibleProperty($object, 'foo'));
```
### Remove files from directory
```php
assertFileDoesNotExist($dir . '/test.txt');
rmdir(__DIR__ . '/runtime');
```
## Support versions
[](https://www.php.net/releases/8.1/en.php)
[](https://yiiframework.com)
## Testing
[Check the documentation testing](/docs/testing.md) to learn about testing.
## Our social networks
[](https://twitter.com/Terabytesoftw)
## License
The MIT License. Please see [License File](LICENSE.md) for more information.