by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Jul 05 22:51
    GrahamCampbell commented #4325
  • Jul 05 12:06
    GrahamCampbell commented #4325
  • Jul 05 09:13
    sebastianbergmann commented #4343
  • Jul 05 09:10

    sebastianbergmann on master

    Sync with https://github.com/ph… (compare)

  • Jul 05 09:00
    localheinz commented #104
  • Jul 05 09:00
    localheinz closed #104
  • Jul 05 08:59
    localheinz synchronize #104
  • Jul 05 08:58
    localheinz synchronize #104
  • Jul 05 08:58
    localheinz synchronize #104
  • Jul 05 08:57
    localheinz opened #104
  • Jul 05 08:44

    sebastianbergmann on master

    Handle mixed return type in tes… (compare)

  • Jul 05 08:35

    sebastianbergmann on master

    Bump Remove superfluous code Rename methods and 10 more (compare)

  • Jul 04 21:56
    Ayesh commented #4325
  • Jul 04 17:03
    codecov[bot] commented #4346
  • Jul 04 17:03
    codecov[bot] commented #4346
  • Jul 04 17:03
    codecov[bot] commented #4346
  • Jul 04 17:02
    codecov[bot] commented #4346
  • Jul 04 17:00
    codecov[bot] commented #4346
  • Jul 04 17:00
    codecov[bot] commented #4346
  • Jul 04 17:00
    epdenouden synchronize #4346
Andreas Möller
@localheinz
11EDC2BC-30CB-42D1-87C1-7F80E2B65850
@sebastianbergmann The error message regarding git when running psalm disappears with sebastianbergmann/phpunit#3838. However, the psalm error remains. Taking a look!
Andreas Möller
@localheinz
@sebastianbergmann @flow-control Global State
Ewout Pieter den Ouden
@epdenouden
@localheinz $_CARPET
Andreas Möller
@localheinz
@epdenouden wat
Ewout Pieter den Ouden
@epdenouden
Stephan Hochdörfer
@shochdoerfer
Food ETA 13:25
Ewout Pieter den Ouden
@epdenouden
@DanielRuf okidoki! I'll treat myself to another round of CliTestDoxPrinter :cherries:
Andreas Heigl
@heiglandreas
I'm digging nito XSLT now....
Michel Hartmann
@MichelHartmann
$foo = $this->createMock(Foo::class);
        $foo->method('doSomething')
            ->after($id); // <- what's the expected behaviour of this method?
Daniel Ruf
@DanielRuf
Marco Pivetta
@Ocramius
Ewout Pieter den Ouden
@epdenouden
for those that don't feel confident fiddling around with Test|TestCase|TestSuite|DataProviderTestSuite...
image.png
Marco Pivetta
@Ocramius
@SenseException Ocramius:chore/annotations-refactoring
@SenseException git@github.com:Ocramius/phpunit.git
Florian Engelhardt
@flow-control
Michel Hartmann
@MichelHartmann
@flow-control seems save to delete them.
Ewout Pieter den Ouden
@epdenouden
Sebastian Bergmann
@sebastianbergmann
@localheinz https://github.com/sebastianbergmann/docker-amiga-gcc/blob/master/Dockerfile ist das einzige Dockerfile, mit dem ich bislang regelmäßig arbeite ;-)
Ewout Pieter den Ouden
@epdenouden
@localheinz I've put the power adapter of your laptop is in Stephan's office your hands
Marco Pivetta
@Ocramius
@sebastianbergmann sebastianbergmann/phpunit#3836 nao green @_@
Oliver Klee
@oliverklee
./tools/psalm --config=.psalm/config.xml
Paul
@gargoyle

Hi. 8.3.4 -> 8.3.5 broke a whole bunch of tests. I've got this method to create a mock guzzle client which will expect a sequence of requests and return a related sequence of responses.

Works fine in 8.3.4. However, 8.3.5 throws this error:-

PHPUnit\Framework\InvalidParameterGroupException: Parameter group #0 must be an array or Traversable, got object

/Users/paul_court/devel/hotelmap/hm-tps/src/tests/Infrastructure/OAuth/OktaClientTest.php:39
/Users/paul_court/devel/hotelmap/hm-tps/src/tests/Infrastructure/OAuth/OktaClientTest.php:51
Oops... missed link to gist with method:- https://gist.github.com/gargoyle/4471bc2e72c75247eefcdc37480552e
Line 39 in the error message is line 31 in the gist... The call to ->withConsecutive(... $allRequests)
Paul
@gargoyle
OK. I figured it out. My request objects needed to be wrapped into an array, but my responses didn't. (Obvious when you think a method can have many args and only 1 return value- :-)
James Van Gelder
@JamesVG1
Does anyone know how to run unit tests?
Daniel Ruf
@DanielRuf
phpunit foldername @JamesVG1
Or path.
Juris
@jurchiks
hey guys, i have a problem with a unit test that seems to have no solution - it involves MockBuilder::enableProxyingToOriginalMethods()
could anyone here help, perhaps?
I was about to write an issue on github, but it suggested to try gitter/stackoverflow first.
Welp, here's the test case for this weird issue: https://gist.github.com/jurchiks/fd690dee6f7215a2eab1d90712463950
The reason for calling enableProxyingToOriginalMethods() in the first place is that I'm trying to mock a class whose parent implements magic methods, and I need those to work.
Thomas B
@gevalo1

Hi! Recently we updated our php version from 7.0.x to 7.3.9 and I'm struggling to get the Dockerfile to run tests in CI to work without warnings/errors.

I keep seeing the following warnings no matter what I try:

  • Warning: DOMDocument::schemaValidate(): Invalid Schema in /***/***/***/vendor/phpunit/phpunit/src/Util/Configuration.php on line 945
  • Warning - The configuration file did not pass validation!
    The following problems have been detected:
    Line 0:
    • failed to load external entity "/***/***/***/vendor/phpunit/phpunit/phpunit.xsd"
    • Failed to locate the main schema resource at '/***/***/***/vendor/phpunit/phpunit/phpunit.xsd'.
      Test results may not be as expected.

It worked fine before using php 7.0.x & phpunit 4.8.26, we now use php 7.3.9 & phpunit 8.3.5.
It also works fine on our own development machines...

Does anyone have an idea what could be going on?

Daniel Ruf
@DanielRuf
@gevalo1 which PHP extensions are installed and loaded?
Thomas B
@gevalo1
@DanielRuf I added both php -i & php -m to this gist: https://gist.github.com/gevalo1/de30abd6856a4bd52ad88b3d9bd03d6e
Leandro Biciato
@Biciato
Hello, i'm getting this exception ReflectionException: Method suite does not exist
Thomas B
@gevalo1
@DanielRuf , The issue is that the Jenkins workspace folder contains an encoded / (%2F). This worked previously, I haven't found what exactly changed to cause the issue but it's definitely not related to PHPUnit.
Stuardo Rodriguez
@stuardo_gitlab
Hi!

I have a method that accepts a param, like public function foo($param) and I had a test that checked if the param was null or false, expecting an exception.

Now, with new typed PHP I can set my public function foo(MyClass $param) and my test now shows me in my IDE that I'm not sending the right param type.

My question is: should I keep my tests that check for an expected exception for null and false? That will help keep checking in the future to see if by any chance the function changes to public function foo(?MyClass $param)
if so, how can I disable the type validation in my IDE/vscode, for those methods?
OR, if I should get rid of the tests, as it feels I'm testing PHP itself to see if the typed params are working.
Thank you all in advance.
Ewout Pieter den Ouden
@epdenouden
goodmorning from Bruxelles and the EU security hackathon
@stuardo_gitlab which also means, somebody is checking on the Gitter chat again ;-)