Download the PHP package amoifr/pickle-panther-bundle without Composer

On this page you can find all versions of the php package amoifr/pickle-panther-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package pickle-panther-bundle

PicklePantherBundle

A YAML-driven end-to-end testing engine for Symfony, built on top of Symfony Panther.

Write browser scenarios in near-natural language (French or English), mapped to PHP "sentences", and get a self-contained HTML report — without a line of Behat/Gherkin glue.

How it works

Piece Role
Scenario YAML Lists scenarios and their ordered steps (sentences + args).
#[Sentence] providers Plain services whose methods are tagged with the sentence(s) they implement.
SentenceRegistry Collects every provider and builds the sentence → method map.
ScenarioRunner Parses a scenario file, applies its context, and runs each step.
BasePantherTest The test case you extend; manages the browser and exposes createScenarioRunner().
AuthenticatorInterface Project-specific login, invoked when a scenario asks for an identity.
HtmlReporter + HtmlReportExtension Accumulate step results and write var/pickle-panther/report.html.

Installation

Register the bundle for the test environment (config/bundles.php):

Browser & driver (required, on the machine that runs the tests)

PicklePanther drives a real, local browser through Symfony Panther — there is no remote/Selenium mode. Two binaries must therefore be present on the same machine/container where PHPUnit runs:

  1. Chrome or Chromium — the actual browser that gets launched.
  2. chromedriver — the WebDriver server Panther talks to.

Their major versions must match (e.g. Chrome 149.x ↔ chromedriver 149.x). A mismatch makes the browser session fail to start (session not created: This version of ChromeDriver only supports Chrome version N).

Install a matching chromedriver the easy way — it lands in ./drivers/, which Panther auto-detects (it searches ./drivers and ./vendor/bin):

Or point to an existing binary explicitly:

Docker / where the browser must live. Because the browser is launched locally by the test process, it must be reachable from wherever PHPUnit runs:

  • PHPUnit inside a container → install Chrome and chromedriver in that container (a browser on the host is not usable from inside the container).
  • PHPUnit on the host → install them on the host. To still exercise an app served elsewhere (e.g. a Dockerised app on https://localhost:444), point the tests at it with PANTHER_EXTERNAL_BASE_URI instead of letting Panther start its own web server.

HTTPS target with a self-signed certificate. Pass the flag through PANTHER_CHROME_ARGUMENTS (read by Panther's ChromeManager), e.g. PANTHER_CHROME_ARGUMENTS=--ignore-certificate-errors. Chrome arguments set only via PHPUnit/bundle capabilities are not forwarded to the launched browser, so the certificate prompt would otherwise block the page.

PHPUnit configuration

Register Panther's web server and the report extension in phpunit.xml.dist:

output_dir (extension parameter / PICKLE_PANTHER_OUTPUT_DIR) should match pickle_panther.report.output_dir so screenshots and the report land together.

Configuration

All keys are optional; defaults are shown.

Keep credentials out of the repository — read them from environment variables.

Where to put the file. If the bundle is only enabled in dev/test (config/bundles.php), put the config under config/packages/test/ (not the root config/packages/): a root file is also loaded in prod, where the bundle is absent, and Symfony would fail with "no extension able to load pickle_panther".

Real-world example

A complete config/packages/test/pickle_panther.yaml, including registering project-specific sentence providers and a French-named role map:

Writing scenarios

A scenario file holds a scenarios list. Keys are bilingual:

French English
nom name
description description
contexte context
navigateur (desktop/mobile) browser
identifié identified
etapes steps
action action
titre title
args args

Two ways to pass arguments

1. Placeholder + args (explicit). The action reuses the registered sentence verbatim and values are listed under args:

args are matched to the method parameters by name when the keys match the parameter names (the natural case, since placeholders mirror parameter names); otherwise they are passed positionally in declaration order.

2. Inline values (concise). Write the value directly inside the brackets and drop args — values are bound to the method parameters positionally, in placeholder order:

The exact-placeholder form always wins the lookup, so the two styles coexist freely. Limitation: an inline value must not contain a closing bracket ] (e.g. CSS attribute selectors like [data-x="y"]) — use the explicit args: form for those.

Bundled sentences

CommonSentences (navigation, clicking, typing, waiting, assertions) and AdminSentences (generic back-office menus/datagrids) ship enabled. Browse them for the exact sentence strings — each method is annotated with its FR and EN #[Sentence].

To list every available sentence (bundled and your own) without reading the code, run the console command — it introspects the registered providers:

Adding your own sentences

Create a provider; autoconfiguration registers it automatically:

$this->client() is the current Panther client; $this->testCase() exposes the PHPUnit assertions.

Authentication

Authentication is project-specific, so it is pluggable.

A scenario then requests a logged-in context:

The HTML report

After the suite finishes, HtmlReportExtension writes a multi-page report next to <output_dir>/report.html:

Screenshots resolve relatively (captures/…), so serving the output directory (or opening report.html) is enough. Set pickle_panther.debug: true (or run with E2E_DEBUG=1) to capture a screenshot on every step, not just failures.

Each report-N.html page also has a slideshow popin to review the captures as a slide deck: the image is centered, the step detail (scenario, title, action with highlighted arguments, OK/FAIL status) sits below with a step counter (e.g. 4 / 48). Open it from the "Diaporama des captures" button or by clicking any capture thumbnail; navigate with the on-screen arrows or the keyboard (←/→), close with the × button, a backdrop click or Esc. It shines with debug enabled (a capture per step) but also works with failure-only captures.

Requirements

Author

Pascal CESCON (@Amoifr) · [email protected]

Changelog

See CHANGELOG.md. This project follows Semantic Versioning.

License

Released under the MIT License.


All versions of pickle-panther-bundle with dependencies

PHP Build Version
Package Version
Requires php Version >=8.2
ext-dom Version *
php-webdriver/webdriver Version ^1.15
phpunit/phpunit Version ^11.0 || ^12.0
symfony/browser-kit Version ^7.1 || ^8.0
symfony/config Version ^7.1 || ^8.0
symfony/console Version ^7.1 || ^8.0
symfony/css-selector Version ^7.1 || ^8.0
symfony/dependency-injection Version ^7.1 || ^8.0
symfony/framework-bundle Version ^7.1 || ^8.0
symfony/http-kernel Version ^7.1 || ^8.0
symfony/panther Version ^2.2
symfony/yaml Version ^7.1 || ^8.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package amoifr/pickle-panther-bundle contains the following files

Loading the files please wait ...