This function allows you to temporarily override an R6 class definition.
It works by creating a subclass then using local_mocked_bindings()
to
temporarily replace the original definition. This means that it will not
affect subclasses of the original class; please file an issue if you need
this.
Learn more about mocking in vignette("mocking")
.