Closed tobollam closed 2 years ago
After deleting the .git dir, cargo mutants can be executed successfully
$ rm -rf .git
$ cargo mutants
Freshen source tree ... ok in 0.107s
Copy source and build products to scratch directory ... 7 MB in 0.216s
Unmutated baseline ... ok in 1.752s
Auto-set test timeout to 20.0s
Found 2 mutations to test
Interesting, thanks! We should probably skip .git
and similar directories.
I guess the root cause here is that the file is read-only, and that cp_r is trying to set the mtime, and on Windows that's probably disallowed on readonly files. (I'm surprised I didn't see this, as I have tested on Windows, but maybe it's something about the git shell.)
Anyhow,
.git
etc.@tobollam, could you try https://github.com/sourcefrog/cargo-mutants/tree/exclude-git in the same environment and let me know if it helps?
@sourcefrog That does solve the problem.
Fixed in e507aefe8140049699635fbe0b1c09363fc51a56 and 8f302e35202ff9aca97faa9239f5dc6cb4283891. There will be a new release soon.
Hi.
I created a simple fizz buzz program as example. Executing 'cargo mutants' leads to the result
after executing
in a git Bash, executing 'cargo mutants' leads to s different result.
I tried it with different projects, but the result is always the same. Before committing everything is fine, after committing I get Access Denied (os error 5).