Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Test Bundle Laravel Package

alexislefebvre/test-bundle

View on GitHub
Deep Wiki
Context7

Upgrade from 1.x version

See Upgrade guide from 1.x to 2.0.

Installation

  1. Download the Bundle

    Open a command console, enter your project directory and execute the following command to download the latest stable version of this bundle:

    $ composer require --dev liip/functional-test-bundle:~2.0@alpha
    

    This command requires you to have Composer installed globally, as explained in the installation chapter of the Composer documentation.

  2. Enable the Bundle

    Add the following line in the app/AppKernel.php file to enable this bundle only for the test environment:

    <?php
    // app/AppKernel.php
    
    // ...
    class AppKernel extends Kernel
    {
        public function registerBundles()
        {
            // ...
            if (in_array($this->getEnvironment(), array('dev', 'test'), true)) {
                // ...
                if ('test' === $this->getEnvironment()) {
                    $bundles[] = new AlexisLefebvre\TestBundle\AlexisLefebvreTestBundle();
                }
            }
    
            return $bundles;
        }
    
        // ...
    }
    
  3. Enable the functionalTest service adding the following empty configuration, ensuring that the framework sets the session name and is using the filesystem for session storage:

    • For symfony 3:

      # app/config/config_test.yml
      alexis_lefebvre_test: ~
      
      # app/config/config_test.yml
      framework:
          test: ~
          session:
              storage_id: session.storage.mock_file
              name: MOCKSESSION
      
    • For symfony 4:

      # config/packages/test/framework.yaml
      framework:
          test: true
          session:
              storage_id: session.storage.mock_file
              name: MOCKSESSION
      
      alexis_lefebvre_test: ~
      
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
bugban/symfony
beyonder-capi/workflow-extensions-bundle
beyonder-capi/job-queue-bundle
capell-app/block-library
axium/identity
cetria/laravel-dummy-models
cetria/reflection-helper
agropredict/sso-auth-bundle
evolvestudio/spam-protection
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin