Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Problem/Motivation
Since phpUnit testing is enabled in the simpletests module the testing is broken under windows.
This because the current integration of phpUnit works on unix plattforms only.
Proposed resolution
Implement an OS independent / specific solution to run phpUnit.
I wasn't able to come up with an OS independent solution thus the attached patch implements a Windows specific command to run phpUnit.
Remaining tasks
reviews needed
User interface changes
none
API changes
none
Comment | File | Size | Author |
---|---|---|---|
#2 | drupal-simpletest-phpunit-windows-2.patch | 1.6 KB | msonnabaum |
drupal-simpletest-phpunit-windows.patch | 1.03 KB | das-peter | |
Comments
Comment #1
amateescu CreditAttribution: amateescu commentedRight, testing is broken for Windows environments, rendering core useless for it's biggest audience atm, core developers :) Tested the patch and I guess it can go in for now, at least as a stop-gap solution.
Comment #2
msonnabaum CreditAttribution: msonnabaum commentedI think this approach is a fine workaround. Sorry for not catching that initially.
Here's a version that decomposes that logic out of the simpletest_phpunit_run_command() function.
Comment #3
amateescu CreditAttribution: amateescu commentedThe new patch works fine too, it just moved the code around a bit.
Comment #4
geerlingguy CreditAttribution: geerlingguy commentedI'm getting the following errors on Mac OS X, using MAMP with PHP 5.3.14:
[Edit: Looks like this may be unrelated; I found that the phpunit test file (supposed to be in
public://simpletest
) is never created, thus the error for me above.]Comment #5
das-peter CreditAttribution: das-peter commentedNever mind, I'm aware that I use an OS underdog :P
Patch looks fine -> RTBC
Comment #6
amateescu CreditAttribution: amateescu commentedUnfortunately, the patch is not fine, OS X has the same issue :(
Comment #7
msonnabaum CreditAttribution: msonnabaum commentedIt's not the same issue. I've identified the MAMP issue and it's different, just has the same symptom. I'll start a new issue for it.
Comment #8
geerlingguy CreditAttribution: geerlingguy commentedMAMP Issue: #1936646: phpunit fails on MAMP.
Comment #9
catchCommitted/pushed to 8.x, thanks!