Buggy code:
; public static void generateTestData ( ) { Object calendarsID = new Integer ( 9 ) ; Object remoteCalendarsID = new Integer ( 100 ) ; Object markID = TestDataGenerator . CATEGORIES [ 0 ] ; Object susanID = TestDataGenerator . CATEGORIES [ 1 ] ; Object michaelID = TestDataGenerator . CATEGORIES [ 2 ] ; Object gregID = TestDataGenerator . CATEGORIES [ 3 ] ; Category root = CategoryDepository . getRoot ( ) ; Category calendars = root . addSubCategory ( calendarsID , "Local" ) ; calendars . addSubCategory ( markID , "Mark" ) ; calendars . addSubCategory ( susanID , "Susan" ) ; calendars . addSubCategory ( michaelID , "Michael" ) ; calendars . addSubCategory ( gregID , "Greg" ) ; root . addSubCategory ( remoteCalendarsID , "Web" ) ; Shape defaultShape = new RoundRectangle ( 0 , 0 , 12 , 12 , 6 , 6 ) ; Color markColor = new Color ( 255 , 180 , 180 ) ; Color markOutlineColor = GfxUtil . tintColor ( markColor , ( - 0.4F ) ) ; CategoryDepository . setOverride ( markID , "bg" , A_PAINT , markColor ) ; CategoryDepository . setOverride ( markID , "bgTrans" , A_PAINT , GfxUtil . alphaColor ( markColor , 145 ) ) ; CategoryDepository . setOverride ( markID , "outline" , A_PAINT , markOutlineColor ) ; CategoryDepository . setOverride ( markID , "treeCheckBox" , A_PAINT , new ShapeGradientPaint ( markColor , 0.2F , 115 , false ) ) ; CategoryDepository . setOverride ( markID , "treeCheckBoxOutline" , A_PAINT , markOutlineColor ) ; CategoryDepository . setOverride ( markID , "titleText" , A_PAINT , markOutlineColor ) ; CategoryDepository . setOverride ( markID , "mainText" , A_PAINT , markOutlineColor ) ; CategoryDepository . setOverride ( markID , "treeCheckBox" , A_SHAPE , defaultShape ) ; CategoryDepository . setOverride ( markID , "treeCheckBoxOutline" , A_SHAPE , defaultShape ) ; Color susanColor = new Color ( 200 , 200 , 255 ) ; Color susanOutlineColor = GfxUtil . tintColor ( susanColor , ( - 0.4F ) ) ; CategoryDepository . setOverride ( susanID , "bg" , A_PAINT , susanColor ) ; CategoryDepository . setOverride ( susanID , "bgTrans" , A_PAINT , GfxUtil . alphaColor ( susanColor , 145 ) ) ; CategoryDepository . setOverride ( susanID , "outline" , A_PAINT , susanOutlineColor ) ; CategoryDepository . setOverride ( susanID , "treeCheckBox" , A_PAINT , new ShapeGradientPaint ( susanColor , 0.2F , 115 , false ) ) ; CategoryDepository . setOverride ( susanID , "treeCheckBoxOutline" , A_PAINT , susanOutlineColor ) ; CategoryDepository . setOverride ( susanID , "titleText" , A_PAINT , susanOutlineColor ) ; CategoryDepository . setOverride ( susanID , "mainText" , A_PAINT , susanOutlineColor ) ; CategoryDepository . setOverride ( susanID , "treeCheckBox" , A_SHAPE , defaultShape ) ; Color michaelColor = new Color ( 255 , 235 , 100 ) ; Color michaelOutlineColor = GfxUtil . tintColor ( michaelColor , ( - 0.4F ) ) ; CategoryDepository . setOverride ( michaelID , "bg" , A_PAINT , michaelColor ) ; CategoryDepository . setOverride ( michaelID , "bgTrans" , A_PAINT , GfxUtil . alphaColor ( michaelColor , 145 ) ) ; CategoryDepository . setOverride ( michaelID , "outline" , A_PAINT , michaelOutlineColor ) ; CategoryDepository . setOverride ( michaelID , "treeCheckBox" , A_PAINT , new ShapeGradientPaint ( michaelColor , 0.2F , 115 , false ) ) ; CategoryDepository . setOverride ( michaelID , "treeCheckBoxOutline" , A_PAINT , michaelOutlineColor ) ; CategoryDepository . setOverride ( michaelID , "titleText" , A_PAINT , michaelOutlineColor ) ; CategoryDepository . setOverride ( michaelID , "mainText" , A_PAINT , michaelOutlineColor ) ; CategoryDepository . setOverride ( michaelID , "treeCheckBox" , A_SHAPE , defaultShape ) ; Color gregColor = new Color ( 180 , 245 , 180 ) ; Color gregOutlineColor = GfxUtil . tintColor ( gregColor , ( - 0.4F ) ) ; CategoryDepository . setOverride ( gregID , "bg" , A_PAINT , gregColor ) ; CategoryDepository . setOverride ( gregID , "bgTrans" , A_PAINT , GfxUtil . alphaColor ( gregColor , 145 ) ) ; CategoryDepository . setOverride ( gregID , "outline" , A_PAINT , gregOutlineColor ) ; CategoryDepository . setOverride ( gregID , "treeCheckBox" , A_PAINT , new ShapeGradientPaint ( gregColor , 0.2F , 115 , false ) ) ; CategoryDepository . setOverride ( gregID , "treeCheckBoxOutline" , A_PAINT , gregOutlineColor ) ; CategoryDepository . setOverride ( gregID , "titleText" , A_PAINT , gregOutlineColor ) ; CategoryDepository . setOverride ( gregID , "mainText" , A_PAINT , gregOutlineColor ) ; CategoryDepository . setOverride ( gregID , "treeCheckBox" , A_SHAPE , defaultShape ) ; calendars . setPropertyDeep ( PROP_IS_HIDDEN , Boolean . FALSE , null ) ; long startMillis = new GregorianCalendar ( 2005 , 0 , 0 ) . getTimeInMillis ( ) ; long endMillis = new GregorianCalendar ( 2005 , 12 , 31 ) . getTimeInMillis ( ) ; ImmutableDateRange dr = new ImmutableDateRange ( startMillis , endMillis , false , null , null ) ; <START_BUG> ArrayList acts = ActivityHelper . createActivities ( dr , TestDataGenerator . TITLES , null , TestDataGenerator . CATEGORIES , null , ( 15 * 60000 ) , ( 60 * 60000 ) , ( ( 24 * 60 ) * 60000 ) , ( 15 * 60000 ) , ( ( 4 * 60 ) * 60000 ) ) ; <END_BUG> ActivityDepository . getInstance ( ) . addBrokedActivities ( acts , TestDataGenerator . class ) ; Activity act = TestDataGenerator . createRecurringEvent ( new GregorianCalendar ( 2004 , 11 , 7 , 11 , 0 ) , new GregorianCalendar ( 2004 , 11 , 7 , 12 , 0 ) , "Mark's<seq2seq4repair_space>Lunch" ) ; act . setCategoryIDs ( new Object [ ] { susanID } ) ; ActivityDepository . getInstance ( ) . addBrokedActivity ( act , TestDataGenerator . class ) ; } public static Activity createRecurringEvent ( Calendar startTime , Calendar endTime , String description ) { } }

Fix:
ArrayList acts = ActivityHelper . createActivities ( dr , TestDataGenerator . TITLES , null , TestDataGenerator . CATEGORIES , null , ( 15 * 60000 ) , ( 60 * 60000 ) , ( ( 24 * 60 ) * 60000 ) , ( 15 * 60000 ) , ( ( 4 * 60 ) * 60000 ) , 10000 ) ;