2016-07-06 5 views
1

を合併していない:あなたはカバレッジは0%Codeceptionリモートカバレッジが、私はCodeceptionの受け入れテストを実行し、結果を得る

で見たよう

enter image description here

をそれから私は_output /受け入れからブラウザでのカバレッジ結果を開きます。 remote.coverage/index.htmlをと参照合計カバレッジ81.13パーセント

enter image description here

質問には、カバレッジ結果がマージされず、コンソールに印刷されない理由があります。すべてのメソッドをカバーするためにユニットテストを書く必要がありますか?ラン・テストコマンドを

actor: Tester 
paths: 
    tests: tests 
    log: tests/_output 
    data: tests/_data 
    support: tests/_support 
    envs: tests/_envs 
settings: 
    bootstrap: _bootstrap.php 
    colors: true 
    memory_limit: 1024M 
coverage: 
    enabled: true 
    c3_url: http://127.0.0.1:4444 
    remote: true 
    whitelist: 
     include: 
      - src/* 
     exclude: 
      - tests/* 
extensions: 
    enabled: 
     - Codeception\Extension\RunFailed 

acceptance.suite.yml

class_name: AcceptanceTester 
modules: 
    enabled: 
     - PhpBrowser: 
      url: http://127.0.0.1:4444 
     - \Helper\Acceptance 

codeception.yml

​​

バージョン

Codeception PHP Testing Framework v2.2.2 
Powered by PHPUnit 5.4.6 by Sebastian Bergmann and contributors. 
+0

同じ問題がありました。http://codeception.com/docs/11-Codecoverage#remote-serverを参照してください。 – fehrlich

答えて

0

documentationに述べたようにCodeceptionは、あなたの結果をマージしません:あなたは別のサーバーでテストを実行する場合

しかし、[...] 1つのオプションは、リモートでなければなりませんconfigに追加されました。
[...]
このオプションを有効にすると、リモートコードカバレッジ結果はローカルのカバレッジ結果とマージされません。マージは、リモートファイルとローカルファイルのパスが同じ場合にのみ可能です。しかし、リモートサーバー上でテストを実行する場合、わからないのです。

多分phpcovを使用して手動で行うことができます。

関連する問題