Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Setting defaultMode on Recorder has no effect #56

Closed
erdi opened this Issue · 1 comment

2 participants

@erdi

given a rule:

@Rule Recorder recorder = new Recorder(defaultMode: READ_ONLY)

I still see that tapes are created for tests if a request doesn't match any of those in the tape

@robfletcher
Owner

This is because of a really annoying limitation of annotation types. An enum property cannot default to null. This means that even if you don't specify the mode property on your annotation it will get set to READ_WRITE because that's the default on the annotation class. If no default is specified then you have to explicitly set it on the annotation. Not sure what, if anything, I can do to get round this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.