donatj / mock-webserver

Simple mock web server in PHP for unit testing.
MIT License
131 stars 21 forks source link

Windows support #42

Closed jonasraoni closed 2 years ago

jonasraoni commented 2 years ago

Hey @donatj,

I just got your v3wip branch, rebased, added minor updates and it's passing through the tests.

donatj commented 2 years ago

Very cool!

I'll need to poke and prod this later, I'm AFK for a couple days, but I'm excited to this.

jonasraoni commented 2 years ago

No problem, I'm just helping another open source project that would like to run their tests under Windows 😁

jonasraoni commented 2 years ago

I've just checked and I can confirm these updates worked for my use case.

donatj commented 2 years ago

Sorry for the delay in getting this merged. I really wanted to get PHP running on a Windows system and give it a try before hand.

After hamfisting my way through getting PHP going on Windows (you guys really configure PATH with a GUI?!) everything appears to work as expected.

donatj commented 2 years ago

Also, I just want to be sassy and add "why you wouldn't just use WSL is a mystery to me" 😆

donatj commented 2 years ago

Hmmph. Once I merged it, I'm getting a semi-consistent CI failure on PHP 5.5... Well that's no fun

jonasraoni commented 2 years ago

you guys really configure PATH with a GUI?!

@donatj Windows got some new things, there's a Windows Server Core, which has no GUI, and the PowerShell. Before the introduction of PowerShell, I think you'd have to use the setx :)

why you wouldn't just use WSL is a mystery to me

I'm just helping another repo, but I think it makes sense to have a test against Windows, considering minor differences might break something (e.g. PHP_EOL) 🤔

CI failure on PHP 5.5

Let me know if you need a hand 😅

jonasraoni commented 2 years ago

Also, if you're ok to release a "broken" package (considering that it wasn't working in Windows anyway, it's already an improvement), I'll use it in the other repository and clear one debt 😅