Skip to content

Commit 1f3e773

Browse files
authored
Update README.md
1 parent 36db36c commit 1f3e773

File tree

1 file changed

+36
-32
lines changed

1 file changed

+36
-32
lines changed

README.md

+36-32
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Robo tasks for Codeception tests parallel execution. Requires [Robo Task Runner]
1111
## Install via Composer
1212

1313
```
14-
"codeception/robo-paracept":"~0.4"
14+
composer require codeception/robo-paracept --dev
1515
```
1616

1717
Include into your RoboFile
@@ -33,7 +33,7 @@ class RoboFile extends \Robo\Tasks
3333

3434
Parallel execution of Codeception tests can be implemented in different ways.
3535
Depending on a project the actual needs can be different.
36-
Thus, we are going to prepare a set of predefined tasks that can be combined and reconfigured to fit needs.
36+
So we prepared a set of predefined Robo tasks that can be combined and reconfigured to fit your needs.
3737

3838
## Tasks
3939

@@ -77,20 +77,46 @@ $this->taskSplitTestsByTime(5)
7777
->run();
7878
```
7979

80-
this command need run all tests with `Codeception\Task\TimeReporter` for collect execution time. If you want just split tests between group (and not execute its) you can use SplitTestsByGroups.
81-
**Please be aware**: This task will not consider any 'depends' annotation!
80+
this command need run all tests with `Codeception\Task\TimeReporter` for collect execution time. If you want just split tests between group (and not execute its) you can use SplitTestsByGroups. **Please be aware**: This task will not consider any 'depends' annotation!
81+
82+
### MergeXmlReports
83+
84+
Mergex several XML reports:
85+
86+
```php
87+
$this->taskMergeXmlReports()
88+
->from('tests/result/result1.xml')
89+
->from('tests/result/result2.xml')
90+
->into('tests/result/merged.xml')
91+
->run();
92+
```
93+
94+
95+
### MergeHtmlReports
96+
97+
Mergex several HTML reports:
98+
99+
```php
100+
$this->taskMergeHtmlReports()
101+
->from('tests/result/result1.html')
102+
->from('tests/result/result2.html')
103+
->into('tests/result/merged.html')
104+
->run();
105+
```
82106

83-
### Filter
107+
108+
## Filters
84109

85110
You can use a custom filter to select the necessary tests.
86111

87112
Two filters already included: DefaultFilter, GroupFilter
88113

89-
**DefaultFilter** is used by default and is every time the first filter which will be used.
90-
**GroupFilter** _Can only be used by taskSplitTestsByGroups_, allows you to filter the loaded tests by the given groups. You have the possibility to declare groups which you want to include or exclude. If you declare foo and bar as included, only tests with this both group annotations will be matched. The same thing is happend when you add excluded groups. If you combine the included and excluded group the only tests which have exactly the correct group annotations for the included items and none of the excluded items.
114+
* **DefaultFilter** is enabled by default, takes all tests.
115+
* **GroupFilter** _(Can only be used by taskSplitTestsByGroups)_, allows you to filter the loaded tests by the given groups. You have the possibility to declare groups which you want to include or exclude. If you declare foo and bar as included, only tests with this both group annotations will be matched. The same thing is happend when you add excluded groups. If you combine the included and excluded group the only tests which have exactly the correct group annotations for the included items and none of the excluded items.
116+
117+
You can add as many filters as you want. The FIFO (First In - First Out) principle applies. The next filter will only get the result of the filter before.
91118

92-
You can add as many filters as you want. The FIFO principle applies. The next filter will only get the result of the filter before.
93-
####USAGE:
119+
### Usage
94120

95121
For example, you want all tests which have in the doc comment the groups 'foo' AND 'bar' but not 'baz' then you can do it like this:
96122

@@ -125,27 +151,5 @@ class CustomFilter extends DefaultFilter {
125151

126152
The TestFileSplitterTask.php pushes an array of SplFileInfo Objects to the filter.
127153
The TestsSplitterTask.php pushes an array of SelfDescribing Objects to the filter.
128-
### MergeXmlReports
129-
130-
Mergex several XML reports:
131-
132-
```php
133-
$this->taskMergeXmlReports()
134-
->from('tests/result/result1.xml')
135-
->from('tests/result/result2.xml')
136-
->into('tests/result/merged.xml')
137-
->run();
138-
```
139154

140-
141-
### MergeHtmlReports
142-
143-
Mergex several HTML reports:
144-
145-
```php
146-
$this->taskMergeHtmlReports()
147-
->from('tests/result/result1.html')
148-
->from('tests/result/result2.html')
149-
->into('tests/result/merged.html')
150-
->run();
151-
```
155+
### License MIT

0 commit comments

Comments
 (0)