EasyMock for the win. Thanks for the suggestion!
No response on hadoop list, but the mock seems like a fine solution to me. In the simplest case you can just make sure that the call to write is called K times, for whatever K, and in the advanced case you can actually capture the outputs. -- David On Wed, Jul 22, 2009 at 4:05 PM, Ted Dunning<[email protected]> wrote: > Or EasyMock. > > These are amazing libraries that actually twiddle byte code in some cases to > emulate classes that would otherwise not be constructable. > > On Wed, Jul 22, 2009 at 2:46 PM, David Hall <[email protected]> wrote: > >> as in JMock? I have 0 experience with JMock, but I'll look into it. >> >> -- David >> >> On Wed, Jul 22, 2009 at 2:42 PM, Ted Dunning<[email protected]> wrote: >> > Can you mock the object? (that counts as using reflection and more, but >> is >> > approved) >> > >> > On Wed, Jul 22, 2009 at 2:33 PM, David Hall <[email protected]> >> wrote: >> > >> >> Also, you can apparently create an inner class by saying >> >> >> >> MyObj.InnerClass ic = myObj.new InnerClass(args); >> >> >> >> This doesn't really get us very far though, without reflection. >> >> >> > >> > > > > -- > Ted Dunning, CTO > DeepDyve >
