File tree Expand file tree Collapse file tree 11 files changed +50
-15
lines changed Expand file tree Collapse file tree 11 files changed +50
-15
lines changed Original file line number Diff line number Diff line change 1- /vendor /
2- /. * /
3- /composer.lock 
1+ /vendor /
2+ /. * /
3+ /composer.lock 
4+ /* .log 
Original file line number Diff line number Diff line change 11notifications :
2-   email : false 
2+   email :
3+     on_success : never 
34
45sudo : false 
56
@@ -23,12 +24,13 @@ cache:
2324    - vendor 
2425
2526install :
26-   - alias composer=composer\ -n && composer selfupdate 
2727  - composer validate 
28-   - composer update $DEPENDENCIES 
28+   - composer --no-interaction  update $DEPENDENCIES 
2929
3030script :
31-   - composer test -- --coverage-clover=build/logs/clover.xml 
31+   - composer test -- --coverage-clover=build/logs/clover.xml --coverage-xml=build/coverage/coverage-xml 
32+     --log-junit=build/coverage/phpunit.junit.xml 
33+   - vendor/bin/infection --min-msi=80 --threads=$(nproc) --coverage=build/coverage 
3234
3335after_success :
3436  - bash <(curl -s https://codecov.io/bash) 
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ Porter <img src="https://github.com/ScriptFUSION/Porter/wiki/images/porter%20222
44[ ![ Latest version] [ Version image ]] [ Releases ] 
55[ ![ Total downloads] [ Downloads image ]] [ Downloads ] 
66[ ![ Build status] [ Build image ]] [ Build ] 
7+ [ ![ Mutation score] [ MSI image ]] [ Build ] 
78[ ![ Test coverage] [ Coverage image ]] [ Coverage ] 
89[ ![ Code style] [ Style image ]] [ Style ] 
910
@@ -580,6 +581,7 @@ Porter is published under the open source GNU Lesser General Public License v3.0
580581  [ Downloads image ] : https://poser.pugx.org/scriptfusion/porter/downloads  " Total downloads " 
581582  [ Build ] : http://travis-ci.org/ScriptFUSION/Porter 
582583  [ Build image ] : https://travis-ci.org/ScriptFUSION/Porter.svg?branch=master  " Build status " 
584+   [ MSI image ] : https://badge.stryker-mutator.io/github.com/ScriptFUSION/Porter/master 
583585  [ Coverage ] : https://codecov.io/gh/ScriptFUSION/Porter 
584586  [ Coverage image ] : https://codecov.io/gh/ScriptFUSION/Porter/branch/master/graphs/badge.svg  " Test coverage " 
585587  [ Style ] : https://styleci.io/repos/49824895 
Original file line number Diff line number Diff line change 1919  },
2020  "require-dev" : {
2121    "amphp/phpunit-util" : " ^1.1" 
22-     "phpunit/phpunit" : " ^7.1.3" 
23-     "mockery/mockery" : " ^1.1" 
22+     "infection/infection" : " ^0.13" 
23+     "mockery/mockery" : " ^1.1" 
24+     "phpunit/phpunit" : " ^7.1.3" 
2425  },
2526  "suggest"  : {
2627    "connectors/http" : " Provides an HTTP connector for Porter providers." 
3839  },
3940  "scripts" : {
4041    "test" : " phpunit -c test" 
42+   },
43+   "config" : {
44+     "sort-packages" : true 
4145  }
4246}
Original file line number Diff line number Diff line change 1+ {
2+     "timeout" : 10 ,
3+     "source" : {
4+         "directories" : [
5+             " src" 
6+         ]
7+     },
8+     "phpUnit" : {
9+         "configDir" : " test" 
10+     },
11+     "logs" : {
12+         "text" : " infection.log" 
13+     },
14+     "mutators" : {
15+         "@default" : true 
16+     }
17+ }
Original file line number Diff line number Diff line change @@ -104,7 +104,7 @@ public function importOne(ImportSpecification $specification): ?array
104104    private  function  fetch (ImportSpecification $ specification\Iterator  
105105    {
106106        $ resource$ specificationgetResource ();
107-         $ provider$ this getProvider ($ specificationgetProviderName () ?:  $ resourcegetProviderClassName ());
107+         $ provider$ this getProvider ($ specificationgetProviderName () ??  $ resourcegetProviderClassName ());
108108
109109        if  ($ resourcegetProviderClassName () !== \get_class ($ provider
110110            throw  new  ForeignResourceException (sprintf (
@@ -175,7 +175,7 @@ public function importOneAsync(AsyncImportSpecification $specification): Promise
175175    private  function  fetchAsync (AsyncImportSpecification $ specificationIterator 
176176    {
177177        $ resource$ specificationgetAsyncResource ();
178-         $ provider$ this getProvider ($ specificationgetProviderName () ?:  $ resourcegetProviderClassName ());
178+         $ provider$ this getProvider ($ specificationgetProviderName () ??  $ resourcegetProviderClassName ());
179179
180180        if  (!$ providerinstanceof  AsyncProvider) {
181181            // TODO: Specific exception type. 
Original file line number Diff line number Diff line change @@ -102,7 +102,7 @@ final public function getTransformers(): array
102102     * 
103103     * @return $this 
104104     */ 
105-     public  function  addTransformer (AnysyncTransformer $ transformerself 
105+     protected  function  addTransformer (AnysyncTransformer $ transformerself 
106106    {
107107        if  ($ this hasTransformer ($ transformer
108108            throw  new  DuplicateTransformerException ('Transformer already added. ' );
Original file line number Diff line number Diff line change 55
66use  ScriptFUSION \Porter \Collection \AsyncRecordCollection ;
77
8+ /** 
9+  * Provides a method to asynchronously transform imported data. 
10+  */ 
811interface  AsyncTransformer extends  AnysyncTransformer
912{
13+     /** 
14+      * Transforms the specified asynchronous record collection, decorated with the specified context data. 
15+      * 
16+      * @param AsyncRecordCollection $records Asynchronous Record collection. 
17+      * @param mixed $context Context data. 
18+      */ 
1019    public  function  transformAsync (AsyncRecordCollection $ records$ contextAsyncRecordCollection 
1120}
Original file line number Diff line number Diff line change 1111interface  Transformer extends  AnysyncTransformer
1212{
1313    /** 
14-      * Transforms the specified record collection decorated with the specified context data. 
14+      * Transforms the specified record collection,  decorated with the specified context data. 
1515     * 
1616     * @param RecordCollection $records Record collection. 
1717     * @param mixed $context Context data. 
Original file line number Diff line number Diff line change @@ -66,7 +66,7 @@ protected function setUp(): void
6666
6767    protected  function  registerProvider (Provider $ providerstring  $ namenull ): void 
6868    {
69-         $ name$ name:  \get_class ($ provider
69+         $ name$ name?  \get_class ($ provider
7070
7171        $ this container 
7272            ->shouldReceive ('has ' )->with ($ nameandReturn (true )
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments