<commit_before># Unit

Unit testing module



### testMethod


Registers a class/method which will be tested.
When you run 'execute' this method will be invoked.
Please, not that it also update the feature section of scenario.

For non-static methods:
````
testMethod('ClassName.MethodName')
````

For static methods:
````
testMethod('ClassName::MethodName')
````


 * @param $signature
### haveFakeClass


Adds stub in internal registry.
Use this command if you need to convert this stub to mock.
Without adding stub to registry you can't trace it's method invocations.


 * @param $instance
### haveStub


Alias for haveFakeClass


 * @alias haveFakeClass

 * @param $instance
### executeTestedMethod


Executes the method which is tested.
If method is not static, the class instance should be provided.
Otherwise bypass the first parameter blank

Include additional arguments as parameter.

Examples:
For non-static methods:
````
executeTestedMethod($object, 1, 'hello', array(5,4,5));
````

The same for static method
```
executeTestedMethod(1, 'hello', array(5,4,5));
```


 * @param $object null

 * @throws \InvalidArgumentException
### executeTestedMethodOn


Alias for executeTestedMethod, only for non-static methods


 * @alias executeTestedMethod

 * @param $object
### seeMethodInvoked





 * @magic

 * @see createMocks

 * @param $mock

 * @param $method

 * @param array $params
### seeMethodInvokedOnce




 * @magic

 * @see createMocks

 * @param $mock

 * @param $method

 * @param array $params
### seeMethodNotInvoked




 * @magic

 * @see createMocks

 * @param $mock

 * @param $method

 * @param array $params
### seeMethodInvokedMultipleTimes




 * @magic

 * @see createMocks

 * @param $mock

 * @param $method

 * @param $times

 * @param array $params
### seeResultEquals

__not documented__
### seeResultContains
<commit_msg>documentation updated<commit_after># Unit

Unit testing module



### testMethod


Registers a class/method which will be tested.
When you run 'execute' this method will be invoked.
Please, not that it also update the feature section of scenario.

For non-static methods:
````
testMethod('ClassName.MethodName')
````

For static methods:
````
testMethod('ClassName::MethodName')
````


 * param $signature
### haveFakeClass


Adds stub in internal registry.
Use this command if you need to convert this stub to mock.
Without adding stub to registry you can't trace it's method invocations.


 * param $instance
### haveStub


Alias for haveFakeClass


 * alias haveFakeClass

 * param $instance
### executeTestedMethod


Executes the method which is tested.
If method is not static, the class instance should be provided.
Otherwise bypass the first parameter blank

Include additional arguments as parameter.

Examples:
For non-static methods:
````
executeTestedMethod($object, 1, 'hello', array(5,4,5));
````

The same for static method
```
executeTestedMethod(1, 'hello', array(5,4,5));
```


 * param $object null

 * throws \InvalidArgumentException
### executeTestedMethodOn


Alias for executeTestedMethod, only for non-static methods


 * alias executeTestedMethod

 * param $object
### seeMethodInvoked





 * magic

 * see createMocks

 * param $mock

 * param $method

 * param array $params
### seeMethodInvokedOnce




 * magic

 * see createMocks

 * param $mock

 * param $method

 * param array $params
### seeMethodNotInvoked




 * magic

 * see createMocks

 * param $mock

 * param $method

 * param array $params
### seeMethodInvokedMultipleTimes




 * magic

 * see createMocks

 * param $mock

 * param $method

 * param $times

 * param array $params
### seeResultEquals

__not documented__
### seeResultContains

{'fraction_non_alphanumeric': 0.1019745739789018, 'fraction_numerical': 0.004327833378414931, 'mean_word_length': 4.22316384180791, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5589971', 'n_tokens_mistral': 1142, 'n_tokens_neox': 1000, 'n_words': 389}