liuggio / fastest

Simple parallel testing execution... with some goodies for functional tests.
MIT License
475 stars 65 forks source link

bin/behat --list-scenarios run them instead of list #65

Closed meshenka closed 8 years ago

meshenka commented 8 years ago

Hi when i do bin/behat --list-scenarios it does not list it run, as if options was ignore (but opions are present in help)

So bin/behat --list-scenarios | bin/fastest "bin/behat {}" does not work properly

bin/behat --help
Usage:
  behat [options] [--] [<paths>]

Arguments:
  paths                                  Optional path(s) to execute. Could be:
                                                      - a Symfony2 bundle path (@BundleName/)
                                                      - a dir (features/)
                                                      - a feature (*.feature)
                                                      - a scenario at specific line (*.feature:10).
                                                      - all scenarios at or after a specific line (*.feature:10-*).
                                                      - all scenarios at a line within a specific range (*.feature:10-20).
                                                      - a scenarios list file (*.scenarios).

Options:
  -s, --suite=SUITE                      Only execute a specific suite.
  -f, --format=FORMAT                    How to format tests output. pretty is default.
                                                      Available formats are:
                                                      - pretty: Prints the feature as is.
                                                      - progress: Prints one character per step.
                                                      - junit: Outputs the failures in JUnit compatible files.
                                                      You can use multiple formats at the same time. (multiple values allowed)
  -o, --out=OUT                          Write format output to a file/directory instead of
                                                      STDOUT (output_path). You can also provide different
                                                      outputs to multiple formats. (multiple values allowed)
      --format-settings=FORMAT-SETTINGS  Set formatters parameters using json object.
                                                      Keys are parameter names, values are values. (multiple values allowed)
      --init                             Initialize all registered test suites.
      --lang=LANG                        Print output in particular language.
      --name=NAME                        Only executeCall the feature elements which match part
                                                      of the given name or regex. (multiple values allowed)
      --tags=TAGS                        Only executeCall the features or scenarios with tags
                                                      matching tag filter expression. (multiple values allowed)
      --role=ROLE                        Only executeCall the features with actor role matching
                                                      a wildcard.
      --story-syntax                     Print *.feature example.
                                                      Use --lang to see specific language.
  -d, --definitions=DEFINITIONS          Print all available step definitions:
                                                      - use --definitions l to just list definition expressions.
                                                      - use --definitions i to show definitions with extended info.
                                                      - use --definitions 'needle' to find specific definitions.
                                                      Use --lang to see definitions in specific language.
      --append-snippets                  Appends snippets for undefined steps into main context.
      --no-snippets                      Do not print snippets for undefined steps after stats.
      --strict                           Passes only if all tests are explicitly passing.
      --order=ORDER                      Set an order in which to execute the specifications (this will result in slower feedback).
      --rerun                            Re-run scenarios that failed during last execution.
      --stop-on-failure                  Stop processing on first failed scenario.
      --dry-run                          Invokes formatters without executing the tests and hooks.
      --list-features                    Output a list of feature files to be executed by Behat
      --list-scenarios                   Output a list of individual scenarios to be executed by Behat

My behat config

default:
  calls:
    error_reporting: 16383 # E_ALL & ~E_USER_DEPRECATED
  suites:
    default:
      contexts:
        - EntityContext
        - AuthenticationContext
        - DoctrineContext
        - Sanpi\Behatch\Context\JsonContext
        - Sanpi\Behatch\Context\RestContext
        - Knp\FriendlyContexts\Context\AliceContext
        - Behat\MinkExtension\Context\MinkContext

  extensions:
    Liuggio\Fastest\Behat\ListFeaturesExtension\Extension: ~

    Behat\Symfony2Extension:
      kernel:
        debug: true
        env: "test"

    Behat\MinkExtension:
      sessions:
        default:
          symfony2: ~

    Sanpi\Behatch\Extension: ~

    Knp\FriendlyContexts\Extension:

My installation

behat/behat                              v3.1.0             Scenario-oriented BDD framework for PHP 5.3
behat/gherkin                            v4.4.1             Gherkin DSL parser for PHP 5.3
behat/mink                               v1.7.1             Browser controller/emulator abstraction for PHP
behat/mink-browserkit-driver             v1.3.2             Symfony2 BrowserKit driver for Mink framework
behat/mink-extension                     v2.2               Mink extension for Behat
behat/symfony2-extension                 2.1.1              Symfony2 framework extension for Behat
behat/transliterator                     v1.1.0             String transliterator
behatch/contexts                         dev-master 627cbe1 Behatch contexts
liuggio/fastest                          1.3.2              Simple parallel testing execution... with some goodies for functional tests.

I"m running php7

php --version
PHP 7.0.4-7ubuntu2 (cli) ( NTS )
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies
    with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2016, by Zend Technologies
aitboudad commented 8 years ago

I had the same issue, It should work again now!