ginkgo icon indicating copy to clipboard operation
ginkgo copied to clipboard

fix running precompiled tests via ginkgo CLI on windows (#529)

Open olegch opened this issue 5 years ago • 5 comments

Hello,

Here is a suggested change to support running precompiled tests on windows via ginkgo CLI (see issue #529 for more details).

olegch avatar Oct 27 '18 22:10 olegch

Change mostly makes sense to me. I wonder if we should start running CI against windows now (https://blog.travis-ci.com/2018-10-11-windows-early-release), I'd like to get some coverage if we are going to be supporting other environments like this.

williammartin avatar Dec 11 '18 11:12 williammartin

One thing that could be improved is to use Go standard library functions that automatically append .exe on Windows. For instance when the exec.LookPath function is called with a path name containing a / (or \ on Windows) it will look for files with a .exe extension. The advantage of this is separation of concerns, and also less code to maintain.

blgm avatar Aug 19 '19 21:08 blgm

Checking on the status of this. Happy to help if needed.

I had originally thought that just getting rid of the exe suffix would have been sufficient but was surprised in my testing to find thats not the case.

johnSchnake avatar May 27 '21 12:05 johnSchnake

sorry y'all i haven't paid enough attention to this issue @johnSchnake can you confirm that this change fixes support for precompiled tests on windows? or are you saying they it doesn't?

i don't have access to a windows box to test it on myself...

onsi avatar May 27 '21 12:05 onsi

Sure thing. I just tried it out and was hacking a bit but when I rebased this onto master, put the exe extension back on my the tests, and ran on an azure k8s cluster I could see tests starting.

prior to all that jazz the master branch would just report no suites found.

A rebase may be all this needs unless you know of other shortcomings I hadn’t seen.

johnSchnake avatar May 27 '21 13:05 johnSchnake