Yesterday I stumbled in this article about mutation testing and immediately tried elasticrepo a I am writing to index github on elasticsearch.
Unfurtunatly it seems that I am missing something because I am not getting the so-called "Killed: rspec" and zero mutations:
lsoave@ubuntu :~/rails/github/elasticrepo$ mutant -I lib/elasticrepo -r repo_subset --rspec-dm2 ::RepoSubset Mutant configuration: Matcher:
Now I think that this may be related to the path, and then here they are in this case:
lsoave@ubuntu :~/rails/github/elasticrepo$ ls -l lib/elasticrepo total 16 -rw-rw-r-- 1 lsoave lsoave 333 Jun 8 16:07 extractor.rb -rw-rw-r-- 1 lsoave lsoave 1960 Jun 8 16:07 indexer.rb -rw-rw-r-- 1 lsoave lsoave 1330 Jun 8 16:07 repo_subset.rb -rw-rw-r-- 1 lsoave lsoave 43 Jun 1 12:28 version.rb lsoave@ubuntu :~/rails/github/elasticrepo$
and here is the "structure" of the class to check (in terms of namespace):
lsoave@ubuntu :~/rails/github/elasticrepo$ head -2 lib/elasticrepo/repo_subset.rb module Elasticrepo class RepoSubset lsoave@ubuntu :~/rails/github/elasticrepo$
Please feel free to use all the code to test the mutation: elasticrepo
It is also possible that something is wrong with the regex due to the response line:
Matcher: #<Mutant::Matcher::ObjectSpace scope_name_pattern=/\ARepoSubset(\z|::)/>
Can anyone help with this?
source share