File tree Expand file tree Collapse file tree 1 file changed +20
-2
lines changed Expand file tree Collapse file tree 1 file changed +20
-2
lines changed Original file line number Diff line number Diff line change @@ -845,10 +845,28 @@ final public function dataSetAsString(): string
845
845
{
846
846
if ($ this ->data !== []) {
847
847
if (is_int ($ this ->dataName )) {
848
- return sprintf (' with data set #%d ' , $ this ->dataName );
848
+ return sprintf (' with data set %s ' , $ this ->dataSetAsFilterString () );
849
849
}
850
850
851
- return sprintf (' with data set "%s" ' , $ this ->dataName );
851
+ return sprintf (' with data set "%s" ' , $ this ->dataSetAsFilterString ());
852
+ }
853
+
854
+ return '' ;
855
+ }
856
+
857
+ /**
858
+ * Returns the data set as a string compatible with the --filter CLI option.
859
+ *
860
+ * @internal This method is not covered by the backward compatibility promise for PHPUnit
861
+ */
862
+ final public function dataSetAsFilterString (): string
863
+ {
864
+ if ($ this ->data !== []) {
865
+ if (is_int ($ this ->dataName )) {
866
+ return sprintf ('#%d ' , $ this ->dataName );
867
+ }
868
+
869
+ return sprintf ('%s ' , $ this ->dataName );
852
870
}
853
871
854
872
return '' ;
You can’t perform that action at this time.
0 commit comments