antonmi / antonmi/espec

Feature: fail_with matcher

Aperta
#265 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
enhancement
Lingua principale
Elixir
Stelle
813
Fork
66
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

It would be useful to have a `fail_with` matcher similar to [RSpecs `fail_with`](http://www.rubydoc.info/gems/rspec-expectations/RSpec/Expectations.fail_with).

Sometimes we have to write some more complex tests which expect certain underlying behaviour from the tested code which is hard to cover with the existing expectations. On some occasions a custom assertions helps but on others such an assertion would be overkill.

Having a simple option to fail a test in an expected manner without raising an arbitrary error would increase test readability a great deal.

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.