Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8258271
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T02:29:03+00:00 2026-06-08T02:29:03+00:00

I have just created a new zend framework application to try out unit testing.

  • 0

I have just created a new zend framework application to try out unit testing.

I have followed this tutorial and everything seems to be working correctly for testing. There is a problem with the display of the coverage report. It displays the correct information, but the report starts at the root of my hard drive and I need to traverse the tree to my project folder to see useful information.

This means that every time I ran the tests, I need to click 5 folders deep to get to the actual report.

How do I make the report start in my project folder? This is my phpunit config file:

<phpunit bootstrap="./bootstrap.php">
    <testsuite name="Application Test Suite">
        <directory>./application</directory>
    </testsuite>
    <testsuite name="Library Test Suite">
        <directory>./library</directory>
    </testsuite>

    <filter>
        <whitelist>
            <directory>../../library/Zend</directory>
            <exclude>
                <directory suffix=".phtml">../application/</directory>
                <file>../application/Bootstrap.php</file>
                <file>../application/controllers/ErrorController.php</file>
            </exclude>          
        </whitelist>
    </filter>

    <logging>
        <log type="coverage-html" target="./log/report" charset="UTF-8" yui="true" 
             hightlight="true" lowupperbound="50" highlowerbound="80">
            <log type="testdox" target="./log/testdox.html">
            </log>
        </log>
    </logging>
</phpunit>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T02:29:05+00:00Added an answer on June 8, 2026 at 2:29 am

    I fixed the problem…

    I needed to explicitly specify my application folder in the whitelist. If it is empty, the code coverage report just starts from ‘c:’ and tries to find every ‘.php’ file.

    After adding the line in the whitelist section:

    <directory>../application/</directory>
    

    It works as expected.

    Since I don’t have any library tests in my test folder, including the Zend library folder probably had no effect and the report must have considered the whitelist empty. And because there is no blacklist, it just started from the root.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to learn about unit testing in Zend Framework. I have installed
I've just installed Zend Framework and am running through a tutorial, but have hit
I am new to Zend framework and have just started working on it. I
I have just created a new facebook application to use in a page tab.
i have just created a new project and this models and the fixtures below:
I have just created a new project with a many-to-many relation (User-Group) and the
I have just created a new project in VS2010 using the Visual c# >
I have a table that we just enabled FileStreams on. We created a new
I have just created this table: create table dbo.OrderTypes ( ID smallint primary key
I have just created 2 pointers which has undefined behavior and try to invoke

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.