Closed mattiasljungstrom closed 4 years ago
Hmm weird, I didn't have problems with fips run
in my projects for running tests on Windows in GH Actions, for instance in the chips-test emulators project:
...and also in the sokol-samples:
Any idea what could be different in your github actions setup? I've been using slashes as path separators since forever in python on Windows and haven't seen any problems with this yet (also outside python, AFAIK forward slashes are generally supported in addition to backslashes)
I'm not sure because it's annoying to test things on github actions. I have CWD setup in fips.yml (see below) and I'm trying to write/read files during my unit tests. But I think the error I'm seeing is before my code is even running.
run:
unit_tests:
cwd: ./
Going to try to figure out where it goes wrong exactly.
Ops, I didn't have run target specified, and the default wasn't the one I was building. But it was on macos, so that's why it worked there. Nothing to see here!
run: python fips run unit_tests win64-vs2019-debug
I think this is because paths are created in the fips code with this style:
return get_workspace_dir(fips_dir) + '/' + proj_name
The same command works on macos VM, but breaks on github Windows for some reason. It works on my build machine, so not sure what's happening exactly on the github VM.
The correct way in python would be to use:
return os.path.join(get_workspace_dir(fips_dir), proj_name)
Do you want me to try to do a PR?
Example run from my project: ` Windows VS2019 debug tests1s shell: C:\Program Files\PowerShell\7\pwsh.EXE -command ". '{0}'" Run python fips run unit_tests python fips run unit_tests shell: C:\Program Files\PowerShell\7\pwsh.EXE -command ". '{0}'"