91carriage / phpunit-hhi
HHI definitions for PHPUnit
Requires
- hhvm: >=3.24.3
Requires (Dev)
Suggests
- 91carriage/dbunit-hhi: HHI files for use with DbUnit
Conflicts
- phpunit/phpunit: <6.2.0
- dev-master / 6.3.x-dev
- dev-phpunit-6.2 / 6.2.x-dev
- 6.2.6
- 6.2.5
- 6.2.4
- 6.2.3
- 6.2.2
- 6.2.1
- 6.2.0
- dev-phpunit-5.7 / 5.7.x-dev
- 5.7.5
- 5.7.4
- 5.7.3
- 5.7.2
- 5.7.1
- 5.7.0
- dev-phpunit-5.6 / 5.6.x-dev
- 5.6.0
- dev-phpunit-5.5 / 5.5.x-dev
- 5.5.0
- dev-phpunit-5.4 / 5.4.x-dev
- 5.4.1
- 5.4.0
- dev-phpunit-5.3 / 5.3.x-dev
- 5.3.0
- dev-phpunit-5.2 / 5.2.x-dev
- 5.2.1
- 5.2.0
- dev-phpunit-5.1 / 5.1.x-dev
- 5.1.1
- 5.1.0
- dev-phpunit-5.0 / 5.0.x-dev
- 5.0.0
- dev-phpunit-4.8 / 4.8.x-dev
- 4.8.2
- 4.8.1
- 4.8.0
- 4.5.0
- dev-hack-testing
This package is auto-updated.
Last update: 2019-02-20 19:34:48 UTC
README
This package provides HHI files for the main PHPUnit package. It does not provide any runtime functionality.
HHI files are files which tell the Hack tools about non-Hack code, providing the necessary names and types to allow Hack to make sure you're using the non-Hack code correctly.
Installation
The easiest way to install this package is with Composer.
To do so, add "91carriage/phpunit-hhi": "~6.2.0" to the require-dev section
of your composer.json or run
composer require --dev '91carriage/phpunit-hhi:~6.2.0'.
It is not recommended to install this as part of your requires section as it
should only be used during development.
Manual installation simply involves downloading the provided source code and copying it into your repository.
Issues
Issues can be submitted to the issue tacker.
If you are unable to create an issue through this, or think that it should not
be publicly disclosed, they can also be emailed directly to
issues@91carriage.com or brought to my attention on IRC, where I
go by the handles simon_w and simon_w|air in the offical #hhvm
channel on FreeNode.
Contributing
Contributions are very welcome. Please make sure that you run hh_client in the
source directory with assume_php=false in your .hhconfig and no errors are
reported.
Code style
For Hack files, the coding style is enforced by the hh_format command, which
is included with the Hack tools alongside hh_client. As the HHI files are decl
files, you need to run hh_format with the --yolo option for these files.
For other files, the basic requirements are:
- Lines are no more than 80 characters wherever possible.
- Indentation is 2 spaces.
- Unix-style (
\n) line endings.
File types
- The HHI files should all be in decl mode.
- The test files should extend
HHITestand be in strict mode. - The HHIT files should be in strict mode.
Non-existent class types
If an object type is required and that object is in a different package or is built into HHVM and doesn't yet have a HHI file, add the expected type as a comment.
For example, if the function foo returns a SplObject and there's no inbuilt
HHI file for SplObject, the definition of foo would be:
function foo() /*: SplObject*/;
License
This code is provided under the MIT (X11 variant) license. The full text of which can be found in the LICENSE.md file.