Skip to content
#

PHPUnit

PHPUnit is a unit testing framework for the PHP programming language. It is an instance of the xUnit architecture for unit testing frameworks.

Here are 975 public repositories matching this topic...

mikehaertl
mikehaertl commented Oct 30, 2019

When learning how to use mocker I came across this paragraph on this page:

When creating a test double object, we can pass in an identifier as a name for our test double. If we pass it no identifier, the test double name will be unknown. Furthermore, the identifier must not be a class name. It i

Codeception
lycenok
lycenok commented Nov 28, 2017

For the step 2:
you should add:
"The database $DB_NAME should be already created"

For the step 3 you should mention where phpunit must run from:

  1. Go to your magento root directory and run unit tests for the first time to install test database by running phpunit. It should take about 3 minutes.
    $ phpunit

Spent some time to figure it out.

valendesigns
valendesigns commented Mar 11, 2019

In the docs it say to use DEV_LIB_SKIP=phpunit git commit to ignore phpunit, but that fails because the git commit portion doesn't seem accurate. Shouldn't it just be DEV_LIB_SKIP=phpunit?

tester
petrparolek
petrparolek commented Sep 24, 2019

Example:

$pattern = "sign/in";
$actual = "https://test.dev/sign/in?_fid=j3o0";
\Tester\Assert::match($pattern, $actual);

Current tester output:

Failed: 'https://test.dev/sign/in?_fid=j3o0' should match
       ... 'sign/in' in testAbc()

It would nice something like:

Failed: 'wrong pattern format given.'
Failed: 'https://test.dev/sign/in?_fid=j3o0' should matc

Created by Sebastian Bergmann

Released March 15, 2004

Repository
sebastianbergmann/phpunit
Website
phpunit.de
Wikipedia
Wikipedia

Related Topics

php
You can’t perform that action at this time.