### Question:
TicketAdminInp extends TicketInp { public static TicketAdminInp instanceForModifyByteWriteNumber(final String ticketId, final long byteWriteLimit) { if (ticketId == null || ticketId.isEmpty()) { throw new IllegalArgumentException("null or empty ticket id"); } if (byteWriteLimit < 0) { throw new IllegalArgumentException("illegal integer for write-byte - must be 0 or greater"); } return new TicketAdminInp(TICKET_ADMIN_INP_API_NBR, "mod", ticketId, "write-byte", String.valueOf(byteWriteLimit), BLANK, BLANK); } private  TicketAdminInp(final int apiNbr, final String arg1, final String arg2, final String arg3, final String arg4,
			final String arg5, final String arg6); static TicketAdminInp instanceForDelete(final String ticketId); static TicketAdminInp instanceForCreate(final TicketCreateModeEnum mode, final String fullPath,
			final String ticketId); static TicketAdminInp instanceForList(final String ticketId); static TicketAdminInp instanceForListAll(); static TicketAdminInp instanceForModifyAddAccess(final String ticketId,
			final TicketModifyAddOrRemoveTypeEnum addTypeEnum, final String modObject); static TicketAdminInp instanceForModifyRemoveAccess(final String ticketId,
			final TicketModifyAddOrRemoveTypeEnum addTypeEnum, final String modObject); static TicketAdminInp instanceForModifyNumberOfUses(final String ticketId, final Integer numberOfUses); static TicketAdminInp instanceForModifyFileWriteNumber(final String ticketId,
			final Integer numberOfFileWrites); static TicketAdminInp instanceForModifyByteWriteNumber(final String ticketId, final long byteWriteLimit); static TicketAdminInp instanceForModifyExpiration(final String ticketId, final String expirationDate); static TicketAdminInp instanceForModifyExpiration(final String ticketId, final Date expirationDate);  }### Answer:
@Test public void testModifyTicketWriteBytes() throws Exception { TicketAdminInp pi = TicketAdminInp.instanceForModifyByteWriteNumber(ticketId, new Integer(555555555)); Assert.assertNotNull(pi); }
@Test public void testModifyTicketWriteBytesCheckXML() throws Exception { TicketAdminInp pi = TicketAdminInp.instanceForModifyByteWriteNumber(ticketId, 500000); String tagOut = pi.getParsedTags(); StringBuilder sb = new StringBuilder(); sb.append("<ticketAdminInp_PI><arg1>mod</arg1>\n"); sb.append("<arg2>ticket_key</arg2>\n"); sb.append("<arg3>write-byte</arg3>\n"); sb.append("<arg4>500000</arg4>\n"); sb.append("<arg5></arg5>\n"); sb.append("<arg6></arg6>\n"); sb.append("</ticketAdminInp_PI>\n"); Assert.assertEquals("unexpected XML protocol result", sb.toString(), tagOut); }
@Test(expected = IllegalArgumentException.class) public void testModifyTicketWriteBytesNullTicketId() throws Exception { TicketAdminInp pi = TicketAdminInp.instanceForModifyByteWriteNumber(null, new Integer(500000)); Assert.assertNotNull(pi); }
@Test(expected = IllegalArgumentException.class) public void testModifyTicketWriteBytesEmptyTicketId() throws Exception { TicketAdminInp pi = TicketAdminInp.instanceForModifyByteWriteNumber("", new Integer(500000)); Assert.assertNotNull(pi); }
@Test public void testModifyTicketWriteBytesZero() throws Exception { TicketAdminInp pi = TicketAdminInp.instanceForModifyByteWriteNumber(ticketId, 0); Assert.assertNotNull(pi); }
@Test(expected = IllegalArgumentException.class) public void testModifyTicketWriteBytesLessThanZero() throws Exception { TicketAdminInp pi = TicketAdminInp.instanceForModifyByteWriteNumber("", new Integer(-100)); Assert.assertNotNull(pi); }