354355356357358359360361362363364
emitter.emitToString(sink, " ", constructor); } finally { sink.close(); } assertEquals(ARGS_TO_STRING, sink.result()); } /** * equals with no args */
371372373374375376377378379380381
emitter.emitEquals(sink, " ", constructor, Util.<String>list()); } finally { sink.close(); } assertEquals(NO_ARG_EQUALS, sink.result()); } /** * equals with args and no types
393394395396397398399400401402403
emitter.emitEquals(sink, " ", constructor, Util.<String>list()); } finally { sink.close(); } assertEquals(ARGS_NO_TYPES_EQUALS, sink.result()); } /** * equals with args and types */
414415416417418419420421422423424
emitter.emitEquals(sink, " ", constructor, list("A", "B")); } finally { sink.close(); } assertEquals(ARGS_TYPES_EQUALS, sink.result()); } /** * hashCode with no args */
431432433434435436437438439440441
emitter.emitHashCode(sink, " ", constructor); } finally { sink.close(); } assertEquals(NO_ARG_HASHCODE, sink.result()); } /** * hashCode with args
459460461462463464465466467
try { emitter.emitHashCode(sink, " ", constructor); } finally { sink.close(); } assertEquals(ARGS_HASHCODE, sink.result()); } }
238239240241242243244245246247248
emitter.emit(sink, fooBar, HEADER); } finally { sink.close(); } assertEquals(HEADER + MULTI_HEADER_NO_BASE + MULTI_CONSTRUCTOR_NO_BASE, sink.result()); } /** * Test that multiple constructors with base types does its thing correctly */
260261262263264265266267268269270
emitter.emit(sink, fooBar, HEADER); } finally { sink.close(); } assertEquals(HEADER + MULTI_HEADER_WITH_BASE + MULTI_CONSTRUCTOR_WITH_BASE, sink.result()); } /** * Test that single constructor with no base does its thing properly */
281282283284285286287288289290291
emitter.emit(sink, fooBar, HEADER); } finally { sink.close(); } assertEquals(HEADER + SINGLE_HEADER_NO_BASE + SINGLE_CONSTRUCTOR_NO_BASE, sink.result()); } /** * Test that single constructor with base does its thing properly */
302303304305306307308309310
emitter.emit(sink, fooBar, HEADER); } finally { sink.close(); } assertEquals(HEADER + SINGLE_HEADER_WITH_BASE + SINGLE_CONSTRUCTOR_WITH_BASE, sink.result()); } }