Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/p-lambert/mutant.el
An Emacs interface for Mutant
https://github.com/p-lambert/mutant.el
emacs mutation-testing
Last synced: 3 months ago
JSON representation
An Emacs interface for Mutant
- Host: GitHub
- URL: https://github.com/p-lambert/mutant.el
- Owner: p-lambert
- Created: 2015-05-12T04:39:42.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2016-02-22T15:56:19.000Z (almost 9 years ago)
- Last Synced: 2023-03-01T20:33:19.304Z (almost 2 years ago)
- Topics: emacs, mutation-testing
- Language: Emacs Lisp
- Size: 15.6 KB
- Stars: 8
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## mutant.el
*An interface for the Mutant testing tool*---
[![MELPA](http://melpa.org/packages/mutant-badge.svg)](http://melpa.org/#/mutant)This package provides an interface for dealing with the
[Mutant](https://github.com/mbj/mutant) testing tool, enabling
one to easily launch it from a `.rb` file or even from a `dired` buffer.
The generated output is nicely formatted and provides direct links
to the errors reported by the mutations. I've tried
to mimic the `rspec-mode` overall experience as much as possible.### Installation
This package can be installed via `MELPA`, or manually by downloading
`mutant.el` and adding it to your init file, as it follows:```elisp
(add-to-list 'load-path "/path/to/mutant")
(require 'mutant)
```For having `mutant-mode` enabled automatically, I suggest you
to do the following:```elisp
(add-hook 'ruby-mode-hook 'mutant-mode)
```### Usage
By default, the following keybindings will be available:
* C-c . f runs `mutant-check-file`
* C-c . c runs `mutant-check-custom`For `dired` mode integration, just add the following to your
configuration file:```elisp
(add-hook 'dired-mode-hook 'mutant-dired-mode)
```By doing so, you'll be able to mark files and then press C-c . f
for running `mutant` on them.See the [Function Documentation](#function-documentation) for more details.
### Customization
If you're a `rvm` user, you might have to add the following to your
configuration file:```elisp
(add-hook 'mutant-precompile-hook
(lambda () (rvm-activate-corresponding-ruby)))
```
Notice that this obviously requires `rvm.el` to be installed.In order to execute the `mutant` command with a `bundle exec` prefix,
simply add the following to your configuration file:```elisp
(setq mutant-cmd-base "bundle exec mutant")
```### Changelog
1.0 - First release.
### Function Documentation
#### `(mutant-check-file &optional FILE-NAME)`
Run Mutant over a single file.
If none is given, then `buffer-file-name` is used.#### `(mutant-check-from-dired)`
Run Mutant over all marked files in dired.
If there are no files marked, use that under cursor.#### `(mutant-check-custom &optional MATCH-EXP)`
Run Mutant over MATCH-EXP.
When called without argument, prompt user.-----