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 8952949
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T13:59:13+00:00 2026-06-15T13:59:13+00:00

I want to start unit testing my symfony 2 application with phpunit. I installed

  • 0

I want to start unit testing my symfony 2 application with phpunit. I installed phpunit using composer (per-project dependancy).
http://www.phpunit.de/manual/current/en/installation.html

How do I now run the phpunit command on Zend Server? I don’t have pear installed.

  • 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-15T13:59:15+00:00Added an answer on June 15, 2026 at 1:59 pm

    If you followed the documentation, you have set the phpunit/phpunit dependency as a ‘dev-dependency’.

    If you don’t have composer, you need to install it first. This is explained in the documentation: Installation *nix or Installation Windows.
    If you already installed composer, it is a good practise to update composer to the latest version by running the self-update command:

    $ php composer.phar self-update
    

    After your have done that, you need to install all dependencies, including the dev dependencies. This is done by running the update command with the --dev switch:

    $ php composer.phar update --dev
    

    All the dependencies are installed in the vendor directory. PHPunit runs from the console. Composer automatic put the console files inside the vendor/bin directory. You need to execute the phpunit file in there:

    $ vendor/bin/phpunit -c app/
    

    The -c switch tells PHPUnit to look for the configuration file in the app directory, Symfony2 already set up the correct configuration to run all tests that are in the <bundle>/Tests directory.

    UPDATE (05-04-2013)

    Composer has changed their update/install commands. update will install dev dependencies by default and if you want to install dev dependencies, you need to use the --dev option.

    UPDATE (11-06-2013)

    Composer has changed their commands again, the install command will also install dev dependencies.

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

Sidebar

Related Questions

I'm trying to start using Unit Testing on my current project in Visual Studio
I want to use xUnit with my project for unit testing. Am using Visual
I want to start to do some unit testing however I am really confused
I just start to study Unit Testing (using FlexUnit). I still have not sure
I'm a new guy to unit testing in .NET and I want to start
I want to start unit testing my javascript files as part of my build
i want to start writing unit tests for my project, what add ons if
I want to start manage application ( Settings -> Application -> manage application ->
I want to start an application which will use ajax push, however the web
I want to start a new thread using a C function, not an objective-C

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.