nus-yam/ex-repair huggingface dataset:
Buggy code:
@ RunWith ( Arquillian . class ) @ RunAsClient public class SignEncryptTestCase { private static Logger log = Logger . getLogger ( SignEncryptTestCase . class . getName ( ) ) ; @ ArquillianResource URL baseUrl ; @ Deployment public static Archive < ? > deployment ( ) { <START_BUG> WebArchive war = ShrinkWrap . create ( WebArchive . class , "jaxws-wsse-sign-encrypt.war" ) . addAsManifestResource ( new StringAsset ( "Dependencies:<seq2seq4repair_space>org.apache.ws.security\n" ) , "MANIFEST.MF" ) . addClasses ( ServiceIface . class , ServiceImpl . class , KeystorePasswordCallback . class ) . addAsResource ( ServiceIface . class . getPackage ( ) , "bob.jks" , "bob.jks" ) . addAsResource ( ServiceIface . class . getPackage ( ) , "bob.properties" , "bob.properties" ) . addAsWebInfResource ( ServiceIface . class . getPackage ( ) , "wsdl//SecurityService.wsdl" , "wsdl//SecurityService.wsdl" ) . addAsWebInfResource ( ServiceIface . class . getPackage ( ) , "wsdl//SecurityService_schema1.xsd" , "wsdl//SecurityService_schema1.xsd" ) . addAsWebInfResource ( SignEncryptTestCase . class . getPackage ( ) , "jaxws-endpoint-config.xml" , "jaxws-endpoint-config.xml" ) ; <END_BUG> SignEncryptTestCase . log . info ( war . toString ( true ) ) ; return war ; } @ Test public void encryptedAndSignedRequest ( ) throws Exception { } private void setupWsse ( ServiceIface proxy ) throws MalformedURLException { } }

Fix:
WebArchive war = ShrinkWrap . create ( WebArchive . class , "jaxws-wsse-sign-encrypt.war" ) . addAsManifestResource ( new StringAsset ( "Dependencies:<seq2seq4repair_space>org.apache.ws.security\n" ) , "MANIFEST.MF" ) . addClasses ( ServiceIface . class , ServiceImpl . class , KeystorePasswordCallback . class ) . addAsResource ( ServiceIface . class . getPackage ( ) , "bob.jks" , "bob.jks" ) . addAsResource ( ServiceIface . class . getPackage ( ) , "bob.properties" , "bob.properties" ) . addAsWebInfResource ( ServiceIface . class . getPackage ( ) , "wsdl//SecurityService-sign-encrypt.wsdl" , "wsdl//SecurityService.wsdl" ) . addAsWebInfResource ( ServiceIface . class . getPackage ( ) , "wsdl//SecurityService_schema1.xsd" , "wsdl//SecurityService_schema1.xsd" ) . addAsWebInfResource ( SignEncryptTestCase . class . getPackage ( ) , "jaxws-endpoint-config.xml" , "jaxws-endpoint-config.xml" ) ;
Buggy code:
public class EditorStack extends PartStack { private EditorSashContainer editorArea ; private WorkbenchPage page ; private SystemMenuSize sizeItem = new SystemMenuSize ( null ) ; private SystemMenuPinEditor pinEditorItem = new SystemMenuPinEditor ( null ) ; public EditorStack ( EditorSashContainer editorArea , WorkbenchPage page ) { } protected WorkbenchPage getPage ( ) { } public void addSystemActions ( IMenuManager menuManager ) { } public boolean isMoveable ( IPresentablePart part ) { } public boolean supportsState ( int state ) { } public static EditorStack newEditorWorkbook ( EditorSashContainer editorArea , WorkbenchPage page ) { } protected void add ( LayoutPart newChild , Object cookie ) { } public void add ( LayoutPart child ) { } protected void updateActions ( PresentablePart current ) { } public Control [ ] getTabList ( ) { } public void removeAll ( ) { } public boolean isActiveWorkbook ( ) { } public void becomeActiveWorkbook ( boolean hasFocus ) { } public EditorPane [ ] getEditors ( ) { } public EditorSashContainer getEditorArea ( ) { } protected boolean canMoveFolder ( ) { } protected void derefPart ( LayoutPart toDeref ) { } protected boolean allowsDrop ( PartPane part ) { } public void setFocus ( ) { } protected void close ( IPresentablePart [ ] parts ) { } public void testInvariants ( ) { } public IStatus restoreState ( IMemento memento ) { } public IStatus saveState ( IMemento memento ) { } public void setMinimized ( boolean minimized ) { } public void setStateLocal ( int newState ) { if ( newState == ( getState ( ) ) ) return ; <START_BUG> super . setMinimized ( ( newState == ( IStackPresentationSite . STATE_MINIMIZED ) ) ) ; <END_BUG> presentationSite . setPresentationState ( newState ) ; } public void showMinMax ( boolean show ) { } }

Fix:
setMinimized ( ( newState == ( IStackPresentationSite . STATE_MINIMIZED ) ) ) ;
Buggy code:
public class DB_Schema { public static void doSchemas ( Connection conn , boolean tablesOnly ) throws SQLException { Statement stmt = conn . createStatement ( ) ; ResultSet rs = stmt . executeQuery ( ( "SELECT<seq2seq4repair_space>SCHEMANAME,<seq2seq4repair_space>SCHEMAID<seq2seq4repair_space>" + "FROM<seq2seq4repair_space>SYS.SYSSCHEMAS" ) ) ; boolean firstTime = true ; while ( rs . next ( ) ) { String sName = dblook . addQuotes ( dblook . expandDoubleQuotes ( rs . getString ( 1 ) ) ) ; if ( tablesOnly || ( dblook . isIgnorableSchema ( sName ) ) ) continue ; if ( sName . equals ( "\"APP\"" ) ) continue ; if ( firstTime ) { Logs . reportString ( "----------------------------------------------" ) ; <START_BUG> Logs . reportMessage ( "CSLOOK_SchemasHeader" ) ; <END_BUG> Logs . reportString ( "----------------------------------------------\n" ) ; } Logs . writeToNewDDL ( ( "CREATE<seq2seq4repair_space>SCHEMA<seq2seq4repair_space>" + sName ) ) ; Logs . writeStmtEndToNewDDL ( ) ; Logs . writeNewlineToNewDDL ( ) ; firstTime = false ; } rs . close ( ) ; stmt . close ( ) ; } }

Fix:
Logs . reportMessage ( "DBLOOK_SchemasHeader" ) ;
Buggy code:
public class ImportWizardLauncher { public ImportWizardLauncher ( ) { } public void launchWizard ( ) { final ImportPluginHandler pluginHandler ; try { pluginHandler = ( ( ImportPluginHandler ) ( pluginManager . getHandler ( "org.columba.mail.import" ) ) ) ; } catch ( PluginHandlerNotFoundException ex ) { NotifyDialog d = new NotifyDialog ( ) ; d . showDialog ( ex ) ; return ; } DataModel data = new DataModel ( ) ; data . registerDataLookup ( "Plugin.handler" , new DataLookup ( ) { public Object lookupData ( ) { return pluginHandler ; } } ) ; WizardModel model = new net . javaprog . ui . wizard . DefaultWizardModel ( new Step [ ] { new PluginStep ( data ) , new LocationStep ( data ) } ) ; model . addWizardModelListener ( new MailboxImporter ( data ) ) ; <START_BUG> Wizard wizard = new Wizard ( model , MailResourceLoader . getString ( "dialog" , "mailboximport" , "title" ) , ImageLoader . getSmallImageIcon ( "stock_convert-32.png" ) ) ; <END_BUG> CSH . setHelpIDString ( wizard , "organising_and_managing_your_email_1" ) ; JavaHelpSupport . enableHelp ( wizard , HelpManager . getHelpBroker ( ) ) ; wizard . pack ( ) ; wizard . setLocationRelativeTo ( null ) ; wizard . setVisible ( true ) ; } }

Fix:
Wizard wizard = new Wizard ( model , MailResourceLoader . getString ( "dialog" , "mailboximport" , "title" ) , ImageLoader . getSmallImageIcon ( "stock_convert.png" ) ) ;
Buggy code:
public class DocumentProcessorTest extends MahoutTestCase { @ Test public void testTokenizeDocuments ( ) throws Exception { Configuration configuration = new Configuration ( ) ; FileSystem fs = FileSystem . get ( configuration ) ; Path input = new Path ( getTestTempDirPath ( ) , "inputDir" ) ; Path output = new Path ( getTestTempDirPath ( ) , "outputDir" ) ; String documentId1 = "123" ; String text1 = "A<seq2seq4repair_space>test<seq2seq4repair_space>for<seq2seq4repair_space>the<seq2seq4repair_space>document<seq2seq4repair_space>processor" ; SequenceFile . Writer writer = new SequenceFile . Writer ( fs , configuration , input , Text . class , Text . class ) ; writer . append ( new Text ( documentId1 ) , new Text ( text1 ) ) ; String documentId2 = "456" ; String text2 = "and<seq2seq4repair_space>another<seq2seq4repair_space>one" ; writer . append ( new Text ( documentId2 ) , new Text ( text2 ) ) ; writer . close ( ) ; <START_BUG> DocumentProcessor . tokenizeDocuments ( input , DefaultAnalyzer . class , output ) ; <END_BUG> FileStatus [ ] statuses = fs . listStatus ( output ) ; assertEquals ( 1 , statuses . length ) ; Path filePath = statuses [ 0 ] . getPath ( ) ; SequenceFile . Reader reader = new SequenceFile . Reader ( fs , filePath , configuration ) ; Text key = reader . getKeyClass ( ) . asSubclass ( Text . class ) . newInstance ( ) ; StringTuple value = reader . getValueClass ( ) . asSubclass ( StringTuple . class ) . newInstance ( ) ; reader . next ( key , value ) ; assertEquals ( documentId1 , key . toString ( ) ) ; assertEquals ( Arrays . asList ( "test" , "document" , "processor" ) , value . getEntries ( ) ) ; reader . next ( key , value ) ; assertEquals ( documentId2 , key . toString ( ) ) ; assertEquals ( Arrays . asList ( "another" , "one" ) , value . getEntries ( ) ) ; } }

Fix:
DocumentProcessor . tokenizeDocuments ( input , DefaultAnalyzer . class , output , configuration ) ;
Buggy code:
public class TestNot extends LuceneTestCase { public TestNot ( String name ) { } public void testNot ( ) throws Exception { RAMDirectory store = new RAMDirectory ( ) ; IndexWriter writer = new IndexWriter ( store , new SimpleAnalyzer ( ) , true , MaxFieldLength . LIMITED ) ; Document d1 = new Document ( ) ; d1 . add ( new org . apache . lucene . document . Field ( "field" , "a<seq2seq4repair_space>b" , Store . YES , Index . ANALYZED ) ) ; writer . addDocument ( d1 ) ; writer . optimize ( ) ; writer . close ( ) ; <START_BUG> Searcher searcher = new IndexSearcher ( store ) ; <END_BUG> QueryParser parser = new QueryParser ( "field" , new SimpleAnalyzer ( ) ) ; Query query = parser . parse ( "a<seq2seq4repair_space>NOT<seq2seq4repair_space>b" ) ; ScoreDoc [ ] hits = searcher . search ( query , null , 1000 ) . scoreDocs ; assertEquals ( 0 , hits . length ) ; } }

Fix:
Searcher searcher = new IndexSearcher ( store , true ) ;
Buggy code:
public class GraphicsOptionsState extends GameState { private MenuButton transition ; private MenuButton antialiasing ; private MenuButton rendering ; private MenuButton fullscreen ; public GraphicsOptionsState ( GamePanel gp ) { } @ Override public void tick ( ) { } @ Override public void draw ( Graphics2D g , double interpolation ) { } @ Override public void restart ( ) { } @ Override public void init ( ) { } public void buttonTransitionAction ( ) { } public void buttonAntialiasingAction ( ) { } public void buttonRenderingAction ( ) { } public void buttonFullscreenAction ( ) { } public void buttonBackAction ( ) { Config . saveConfig ( ) ; <START_BUG> gsm . transition ( this , OPTIONSMENU_STATE , BLACKFADE ) ; <END_BUG> } @ Override public void init ( Object o ) { } }

Fix:
gsm . popTransition ( BLACKFADE ) ;
Buggy code:
public class TreeTest extends WicketTestCase { private static Log log = LogFactory . getLog ( TreeTest . class ) ; public TreeTest ( String name ) { } public void testRenderTreePage_1 ( ) throws Exception { } public void testRenderTreePageWithBorder_1 ( ) throws Exception { executeTest ( TreePageWithBorder . class , "TreePageWithBorderExpectedResult_1.html" ) ; Page page = application . getLastRenderedPage ( ) ; application . setupRequestAndResponse ( ) ; <START_BUG> application . getServletRequest ( ) . setRequestToRedirectString ( "?path=0:border:tree:tree:3:node:junctionLink&interface=ILinkListener" ) ; <END_BUG> application . processRequestCycle ( ) ; String document = application . getServletResponse ( ) . getDocument ( ) ; assertTrue ( DiffUtil . validatePage ( document , this . getClass ( ) , "TreePageWithBorderExpectedResult_1-1.html" ) ) ; } public void testRenderTreePageNoWicketHeadTag_1 ( ) throws Exception { } }

Fix:
application . getServletRequest ( ) . setRequestToRedirectString ( "?path=0:tree:tree:3:node:junctionLink&interface=ILinkListener" ) ;
Buggy code:
public class XPA extends MFSK { private int baudRate = 10 ; private int state = 0 ; private double samplesPerSymbol ; private Rivet theApp ; private long sampleCount = 0 ; private long symbolCounter = 0 ; private String previousCharacter ; private int groupCount = 0 ; private StringBuffer lineBuffer = new StringBuffer ( ) ; private CircularDataBuffer energyBuffer = new CircularDataBuffer ( ) ; private long syncFoundPoint ; private int longCorrectionFactor ; private int shortCorrectionFactor ; public XPA ( Rivet tapp , int baud ) { } public void setBaudRate ( int baudRate ) { } public int getBaudRate ( ) { } public void setState ( int state ) { } public int getState ( ) { } public String [ ] decode ( CircularDataBuffer circBuf , WaveData waveData ) { } private String startToneHunt ( CircularDataBuffer circBuf , WaveData waveData ) { String line ; final int HighTONE = 1280 ; final int LowTONE = 520 ; final int toneDIFFERENCE = HighTONE - LowTONE ; final int ErrorALLOWANCE = 40 ; int tone1 = do1024FFT ( circBuf , waveData , 0 ) ; int tone2 = do1024FFT ( circBuf , waveData , ( ( ( int ) ( samplesPerSymbol ) ) * 1 ) ) ; if ( tone1 != tone2 ) return null ; int tone3 = do1024FFT ( circBuf , waveData , ( ( ( int ) ( samplesPerSymbol ) ) * 2 ) ) ; if ( tone1 > tone3 ) return null ; int tone4 = do1024FFT ( circBuf , waveData , ( ( ( int ) ( samplesPerSymbol ) ) * 3 ) ) ; if ( ( tone1 != tone2 ) || ( tone3 != tone4 ) ) return null ; if ( tone2 == tone3 ) return null ; int difference = tone3 - tone1 ; if ( ( difference < ( toneDIFFERENCE - ErrorALLOWANCE ) ) || ( difference > ( toneDIFFERENCE + ErrorALLOWANCE ) ) ) return null ; longCorrectionFactor = LowTONE - tone1 ; <START_BUG> int stone = do128FFT ( circBuf , waveData , ( ( ( int ) ( samplesPerSymbol ) ) * 1 ) ) ; <END_BUG> shortCorrectionFactor = LowTONE - stone ; line = ( ( ( theApp . getTimeStamp ( ) ) + "<seq2seq4repair_space>XPA<seq2seq4repair_space>Start<seq2seq4repair_space>Tones<seq2seq4repair_space>Found<seq2seq4repair_space>(correcting<seq2seq4repair_space>by<seq2seq4repair_space>" ) + ( Integer . toString ( longCorrectionFactor ) ) ) + "<seq2seq4repair_space>Hz)" ; return line ; } private String getChar ( int tone , String prevChar ) { } private String [ ] displayMessage ( int freq , boolean isFile ) { } }

Fix:
int stone = do128FFT ( circBuf , waveData , 0 ) ;
Buggy code:
public final class ImmutableDistanceImpl implements Distance { private final int mId ; private final Trip mTrip ; private final String mLocation ; private final BigDecimal mDistance ; private final Date mDate ; private final TimeZone mTimezone ; private final BigDecimal mRate ; private final Price mPrice ; private final String mComment ; public ImmutableDistanceImpl ( int id , Trip trip , String location , BigDecimal distance , BigDecimal rate , WBCurrency currency , Date date , TimeZone timeZone , String comment ) { } protected ImmutableDistanceImpl ( Parcel in ) { } @ Override public int getId ( ) { } @ Override @ NonNull public Trip getTrip ( ) { } @ Override public String getLocation ( ) { } @ Override public BigDecimal getDistance ( ) { } @ Override public String getDecimalFormattedDistance ( ) { } @ Override public Date getDate ( ) { } @ Override public String getFormattedDate ( Context context , String separator ) { } @ Override public TimeZone getTimeZone ( ) { } @ Override public BigDecimal getRate ( ) { } @ Override public String getDecimalFormattedRate ( ) { <START_BUG> return ModelUtils . getDecimalFormattedValue ( mRate ) ; <END_BUG> } @ Override public String getCurrencyFormattedRate ( ) { } @ NonNull @ Override public Price getPrice ( ) { } @ Override public String getComment ( ) { } @ Override public int describeContents ( ) { } @ Override public void writeToParcel ( Parcel dest , int flags ) { } public static final Creator < ImmutableDistanceImpl > CREATOR = new Creator < ImmutableDistanceImpl > ( ) { @ Override public ImmutableDistanceImpl createFromParcel ( Parcel in ) { } @ Override public ImmutableDistanceImpl [ ] newArray ( int size ) { } } ; @ Override public String toString ( ) { } @ Override public int hashCode ( ) { } @ Override public boolean equals ( Object obj ) { } }

Fix:
return ModelUtils . getDecimalFormattedValue ( mRate , 3 ) ;
Buggy code:
public class Version { public static final String getVersion ( ) { <START_BUG> return "0.4.2-USS-SNAPSHOT" ; <END_BUG> } }

Fix:
return "0.5" ;
Buggy code:
public class Competition { private ArrayList < Match > matches ; public Competition ( ) { } public void add ( Match match ) { } public String toString ( ) { } public String toWrite ( ) { String write = "<Competition>\r\n" ; <START_BUG> for ( int i = 1 ; i < 34 ; i ++ ) { <END_BUG> write += "<seq2seq4repair_space><Round>\r\n" ; write += ( "<seq2seq4repair_space><Day>" + i ) + "<//Day>\r\n" ; ArrayList < Match > day = getMatchesForDay ( i ) ; for ( Match m : day ) { write += m . toWrite ( ) ; } write += "<seq2seq4repair_space><//Round>\r\n" ; } for ( int i = 0 ; i < ( matches . size ( ) ) ; i ++ ) { write += matches . get ( i ) . toWrite ( ) ; } write += "<//Competition>\r\n" ; return write ; } public int getSize ( ) { } public Match get ( int index ) { } public ArrayList < Match > getMatchesForDay ( int day ) { } }

Fix:
for ( int i = 1 ; i <= 34 ; i ++ ) {
Buggy code:
public class JPADependencyProcessor implements DeploymentUnitProcessor { private static final ModuleIdentifier JAVAX_PERSISTENCE_API_ID = ModuleIdentifier . create ( "javax.persistence.api" ) ; private static final ModuleIdentifier JAVAEE_API_ID = ModuleIdentifier . create ( "javaee.api" ) ; private static final ModuleIdentifier JBOSS_AS_JPA_ID = ModuleIdentifier . create ( "org.jboss.as.jpa" ) ; private static final ModuleIdentifier JBOSS_AS_JPA_SPI_ID = ModuleIdentifier . create ( "org.jboss.as.jpa.spi" ) ; private static final ModuleIdentifier JAVASSIST_ID = ModuleIdentifier . create ( "org.javassist" ) ; private static final ModuleIdentifier HIBERNATE_3_PROVIDER = ModuleIdentifier . create ( "org.jboss.as.jpa.hibernate" , "3" ) ; private static final String HIBERNATE3_PROVIDER_ADAPTOR = "org.jboss.as.jpa.hibernate3.HibernatePersistenceProviderAdaptor" ; private static final ModuleIdentifier HIBERNATE_ENVERS_ID = ModuleIdentifier . create ( "org.hibernate.envers" ) ; private static final ModuleIdentifier JBOSS_AS_NAMING_ID = ModuleIdentifier . create ( "org.jboss.as.naming" ) ; private static final ModuleIdentifier JBOSS_JANDEX_ID = ModuleIdentifier . create ( "org.jboss.jandex" ) ; public void deploy ( DeploymentPhaseContext phaseContext ) throws DeploymentUnitProcessingException { } private void addDependency ( ModuleSpecification moduleSpecification , ModuleLoader moduleLoader , ModuleIdentifier moduleIdentifier ) { <START_BUG> moduleSpecification . addSystemDependency ( new org . jboss . as . server . deployment . module . ModuleDependency ( moduleLoader , moduleIdentifier , false , false , false ) ) ; <END_BUG> } @ Override public void undeploy ( DeploymentUnit context ) { } private void addPersistenceProviderModuleDependencies ( DeploymentPhaseContext phaseContext , ModuleSpecification moduleSpecification , ModuleLoader moduleLoader ) throws DeploymentUnitProcessingException { } private int loadPersistenceUnits ( final ModuleLoader moduleLoader , final DeploymentUnit deploymentUnit , final Set < String > moduleDependencies , final PersistenceUnitMetadataHolder holder ) throws DeploymentUnitProcessingException { } private void addHibernate3AdaptorToDeployment ( final ModuleLoader moduleLoader , final DeploymentUnit deploymentUnit ) { } }

Fix:
moduleSpecification . addSystemDependency ( new org . jboss . as . server . deployment . module . ModuleDependency ( moduleLoader , moduleIdentifier , false , false , false , false ) ) ;
Buggy code:
public class PasteFromListDialog extends EnhancedDialog { public PasteFromListDialog ( String name , View view , ListModel model ) { } public void ok ( ) { } public void cancel ( ) { } private View view ; private JList clips ; private JTextArea clipText ; private JButton insert ; private JButton cancel ; private String getSelectedClipText ( ) { } private void updateButtons ( ) { } private void showClipText ( ) { } class Renderer extends DefaultListCellRenderer { String shorten ( String item ) { } public Component getListCellRendererComponent ( JList list , Object value , int index , boolean isSelected , boolean cellHasFocus ) { super . getListCellRendererComponent ( list , value , index , isSelected , cellHasFocus ) ; <START_BUG> setText ( shorten ( ( ( String ) ( value ) ) ) ) ; <END_BUG> return this ; } } class ActionHandler implements ActionListener { public void actionPerformed ( ActionEvent evt ) { } } class ListHandler implements ListSelectionListener { public void valueChanged ( ListSelectionEvent evt ) { } } class MouseHandler extends MouseAdapter { public void mouseClicked ( MouseEvent evt ) { } } }

Fix:
setText ( shorten ( value . toString ( ) ) ) ;
Buggy code:
public class RandomWeightMatrixGenerator { public static int BLOCK_SIZE = 5000 ; public static void main ( String [ ] args ) throws IOException { } private static void generateFastSimpleWeights ( String [ ] args ) { String outDir = args [ 0 ] ; int size = Integer . parseInt ( args [ 1 ] ) ; int splits = Integer . parseInt ( args [ 2 ] ) ; <START_BUG> short weight = Short . parseShort ( args [ 5 ] ) ; <END_BUG> int q = size // splits ; int r = size % splits ; byte [ ] bytes = new byte [ ] { ( ( byte ) ( ( weight > > 8 ) & 255 ) ) , ( ( byte ) ( weight & 255 ) ) } ; final byte [ ] weightRow = new byte [ size * ( Short . BYTES ) ] ; IntStream . range ( 0 , size ) . parallel ( ) . forEach ( ( i ) -> { weightRow [ ( 2 * i ) ] = bytes [ 0 ] ; weightRow [ ( ( 2 * i ) + 1 ) ] = bytes [ 1 ] ; } ) ; IntStream . range ( 0 , splits ) . parallel ( ) . forEach ( ( i ) -> { Path file = Paths . get ( outDir , ( ( ( "w" + weight ) + "_" ) + i ) ) ; try ( BufferedOutputStream bos = new BufferedOutputStream ( Files . newOutputStream ( file , StandardOpenOption . CREATE_NEW ) ) ) { int rows = ( ( i + 1 ) * q ) + ( i < r ? i + 1 : r ) ; for ( int row = 0 ; row < rows ; ++ i ) { bos . write ( weightRow ) ; } } catch ( IOException e ) { e . printStackTrace ( ) ; } } ) ; } }

Fix:
short weight = Short . parseShort ( args [ 3 ] ) ;
Buggy code:
public class PooledConnectionFactoryAdd extends AbstractAddStepHandler implements DescriptionProvider { public static final PooledConnectionFactoryAdd INSTANCE = new PooledConnectionFactoryAdd ( ) ; protected void populateModel ( ModelNode operation , ModelNode model ) throws OperationFailedException { <START_BUG> AlternativeAttributeCheckHandler . checkAlternatives ( operation , CONNECTOR . getName ( ) , DISCOVERY_GROUP_NAME . getName ( ) ) ; <END_BUG> for ( final AttributeDefinition attribute : ConnectionFactoryAttribute . getDefinitions ( ATTRIBUTES ) ) { attribute . validateAndSet ( operation , model ) ; } } protected void performRuntime ( OperationContext context , ModelNode operation , ModelNode model , ServiceVerificationHandler verificationHandler , List < ServiceController < ? > > newControllers ) throws OperationFailedException { } static List < String > getConnectors ( final ModelNode model ) { } static String getDiscoveryGroup ( final ModelNode model ) { } static List < PooledConnectionFactoryConfigProperties > getAdapterParams ( ModelNode model , OperationContext context ) throws OperationFailedException { } @ Override public ModelNode getModelDescription ( Locale locale ) { } }

Fix:
AlternativeAttributeCheckHandler . checkAlternatives ( operation , CONNECTOR . getName ( ) , DISCOVERY_GROUP_NAME . getName ( ) , false ) ;
Buggy code:
public class Load implements Command { private static transient Logger log = Hierarchy . getDefaultHierarchy ( ) . getLoggerFor ( "jmeter.gui" ) ; private static Set commands = new HashSet ( ) ; public Load ( ) { } public Set getActionNames ( ) { } public void doAction ( ActionEvent e ) { } public boolean insertLoadedTree ( int id , HashTree tree ) throws Exception , IllegalUserActionException { } private void convertTree ( HashTree tree ) throws Exception { } private JMeterGUIComponent generateGUIComponent ( TestElement item ) throws Exception { JMeterGUIComponent gui = null ; try { <START_BUG> gui = ( ( JMeterGUIComponent ) ( Class . forName ( ( ( String ) ( item . getProperty ( GUI_CLASS ) ) ) ) . newInstance ( ) ) ) ; <END_BUG> } catch ( Exception e ) { Load . log . warn ( ( "Couldn't<seq2seq4repair_space>get<seq2seq4repair_space>gui<seq2seq4repair_space>for<seq2seq4repair_space>" + item ) , e ) ; gui = new WorkBenchGui ( ) ; } gui . configure ( item ) ; return gui ; } public static class Test extends TestCase { File testFile1 ; File testFile2 ; File testFile3 ; File testFile4 ; File testFile5 ; File testFile6 ; File testFile7 ; File testFile8 ; File testFile9 ; File testFile10 ; File testFile11 ; File testFile12 ; File testFile13 ; static Load loader = new Load ( ) ; public Test ( String name ) { } public void setUp ( ) { } public void testFile3 ( ) throws Exception { } public void testFile4 ( ) throws Exception { } public void testFile5 ( ) throws Exception { } public void testFile6 ( ) throws Exception { } public void testFile7 ( ) throws Exception { } public void testFile8 ( ) throws Exception { } public void testFile9 ( ) throws Exception { } public void testFile10 ( ) throws Exception { } public void testFile11 ( ) throws Exception { } public void testFile12 ( ) throws Exception { } private HashTree getTree ( File f ) throws Exception { } } }

Fix:
gui = ( ( JMeterGUIComponent ) ( Class . forName ( item . getPropertyAsString ( GUI_CLASS ) ) . newInstance ( ) ) ) ;
Buggy code:
public class PackagedTextTemplate extends TextTemplate { private static final long serialVersionUID = 1L ; private static Log log = LogFactory . getLog ( PackagedTextTemplate . class ) ; private static final ClassLoaderResourceStreamLocator streamLocator = new ClassLoaderResourceStreamLocator ( ) ; private StringBuffer buffer = new StringBuffer ( ) ; public PackagedTextTemplate ( final Class clazz , final String fileName ) { } public PackagedTextTemplate ( final Class clazz , final String fileName , final String contentType ) { } public PackagedTextTemplate ( final Class clazz , final String fileName , final String contentType , final String encoding ) { } <START_BUG> public final PackagedTextTemplate interpolate ( Map variables ) { <END_BUG> if ( variables != null ) { String result = new MapVariableInterpolator ( buffer . toString ( ) , variables ) . toString ( ) ; buffer . delete ( 0 , buffer . length ( ) ) ; buffer . append ( result ) ; } return this ; } public final long length ( ) { } public String getString ( ) { } }

Fix:
public final TextTemplate interpolate ( Map variables ) {
Buggy code:
public class UserDestinationMessageHandler implements MessageHandler { private static final Log logger = LogFactory . getLog ( UserDestinationMessageHandler . class ) ; private final MessageSendingOperations < String > messagingTemplate ; private String prefix = "//user//" ; private UserSessionResolver userSessionResolver = new InMemoryUserSessionResolver ( ) ; public UserDestinationMessageHandler ( MessageSendingOperations < String > messagingTemplate ) { } public void setPrefix ( String prefix ) { } public String getPrefix ( ) { } public void setUserSessionResolver ( UserSessionResolver userSessionResolver ) { } public UserSessionResolver getUserSessionResolver ( ) { } public MessageSendingOperations < String > getMessagingTemplate ( ) { } @ Override public void handleMessage ( Message < ? > message ) throws MessagingException { } protected boolean shouldHandle ( Message < ? > message ) { } private class UserDestinationParser { private final String user ; private final String targetDestination ; public UserDestinationParser ( String destination ) { } public String getUser ( ) { } public String getTargetDestination ( String sessionId ) { <START_BUG> return ( this . targetDestination ) != null ? ( ( this . targetDestination ) + "//" ) + sessionId : null ; <END_BUG> } } }

Fix:
return ( this . targetDestination ) != null ? ( this . targetDestination ) + sessionId : null ;
Buggy code:
public class Parser { static final String COMMAND_EXIT = "exit" ; static final String COMMAND_CLEAR = "clear" ; static final String COMMAND_SHOW = "show" ; static final String COMMAND_DELETE = "delete" ; static final String COMMAND_MARK = "mark" ; static final String COMMAND_EDIT = "edit" ; static final String COMMAND_ADD = "add" ; static final String COMMAND_ADD_CAT = "addcat" ; static final String COMMAND_SKIN = "skin" ; static final String COMMAND_STORAGE = "storage" ; private static final String COMMAND_UNMARK = "unmark" ; public Parser ( ) { } public Command getCommand ( String input ) { input = input . trim ( ) ; if ( input == "" ) { Main . showToUser ( MESAGE_EMPTY_COMMAND ) ; return null ; } String [ ] splittedInput = input . split ( "\\s+" , 2 ) ; String commandString = splittedInput [ 0 ] ; Command command = null ; switch ( commandString . toLowerCase ( ) ) { case Parser . COMMAND_ADD : AddParser addParser = new AddParser ( getInputWithoutCommand ( input , Parser . COMMAND_ADD ) ) ; command = addParser . getCommand ( ) ; break ; case Parser . COMMAND_SHOW : ShowParser showParser = new ShowParser ( getInputWithoutCommand ( input , Parser . COMMAND_SHOW ) ) ; command = showParser . getCommand ( ) ; break ; case Parser . COMMAND_EDIT : EditParser editParser = new EditParser ( getInputWithoutCommand ( input , Parser . COMMAND_EDIT ) ) ; command = editParser . getCommand ( ) ; break ; case Parser . COMMAND_DELETE : DeleteParser deleteParser = new DeleteParser ( getInputWithoutCommand ( input , Parser . COMMAND_DELETE ) ) ; command = deleteParser . getCommand ( ) ; break ; case Parser . COMMAND_MARK : <START_BUG> UnmarkParser markParser = new UnmarkParser ( getInputWithoutCommand ( input , Parser . COMMAND_MARK ) ) ; <END_BUG> command = markParser . getCommand ( ) ; break ; case Parser . COMMAND_ADD_CAT : AddCatParser addCatParser = new AddCatParser ( getInputWithoutCommand ( input , Parser . COMMAND_ADD_CAT ) ) ; command = addCatParser . getCommand ( ) ; break ; case Parser . COMMAND_SKIN : String colour = getInputWithoutCommand ( input , Parser . COMMAND_SKIN ) ; break ; case Parser . COMMAND_STORAGE : String filePath = getInputWithoutCommand ( input , Parser . COMMAND_STORAGE ) ; break ; case Parser . COMMAND_UNMARK : UnmarkParser unmarkParser = new UnmarkParser ( getInputWithoutCommand ( input , Parser . COMMAND_MARK ) ) ; break ; case Parser . COMMAND_EXIT : command = CommandUtils . createExitCommand ( ) ; break ; default : command = CommandUtils . createInvalidCommand ( ( "Invalid<seq2seq4repair_space>Command:<seq2seq4repair_space>" + input ) ) ; } return command ; } private String getInputWithoutCommand ( String input , String command ) { } }

Fix:
MarkParser markParser = new MarkParser ( getInputWithoutCommand ( input , Parser . COMMAND_MARK ) ) ;
Buggy code:
public class NewMethodTypeMunger extends ResolvedTypeMunger { public NewMethodTypeMunger ( ResolvedMember signature , Set superMethodsCalled , List typeVariableAliases ) { } public ResolvedMember getInterMethodBody ( UnresolvedType aspectType ) { } public ResolvedMember getInterMethodDispatcher ( UnresolvedType aspectType ) { } public void write ( DataOutputStream s ) throws IOException { } public static ResolvedTypeMunger readMethod ( VersionedDataInputStream s , ISourceContext context ) throws IOException { } public ResolvedMember getMatchingSyntheticMember ( Member member , ResolvedType aspectType ) { } public ResolvedTypeMunger parameterizedFor ( ResolvedType target ) { ResolvedType genericType = target ; if ( ( target . isRawType ( ) ) || ( target . isParameterizedType ( ) ) ) genericType = genericType . getGenericType ( ) ; <START_BUG> ResolvedMember parameterizedSignature = getSignature ( ) . parameterizedWith ( target . getTypeParameters ( ) , genericType , target . isParameterizedType ( ) ) ; <END_BUG> return new NewMethodTypeMunger ( parameterizedSignature , getSuperMethodsCalled ( ) , typeVariableAliases ) ; } }

Fix:
ResolvedMember parameterizedSignature = getSignature ( ) . parameterizedWith ( target . getTypeParameters ( ) , genericType , target . isParameterizedType ( ) , typeVariableAliases ) ;
Buggy code:
public class WicketTagPanelTest extends TestCase { private MockHttpApplication application ; public WicketTagPanelTest ( String name ) { } protected void setUp ( ) throws Exception { super . setUp ( ) ; application = new MockHttpApplication ( null ) ; <START_BUG> application . getSettings ( ) . setHomePage ( WicketPanelPage . class ) ; <END_BUG> } public void testRenderHomePage ( ) throws Exception { } }

Fix:
application . getPages ( ) . setHomePage ( WicketPanelPage . class ) ;
Buggy code:
public class WorldProviderHole extends WorldProviderSpace implements IGalacticraftWorldProvider { @ Override public Vector3 getFogColor ( ) { } @ Override public Vector3 getSkyColor ( ) { } @ Override public boolean canRainOrSnow ( ) { } @ Override public boolean hasSunset ( ) { } @ Override public long getDayLength ( ) { } @ Override public boolean shouldForceRespawn ( ) { } @ Override public Class < ? extends IChunkProvider > getChunkProviderClass ( ) { } @ Override public Class < ? extends WorldChunkManager > getWorldChunkManagerClass ( ) { } @ Override public void setDimension ( int var1 ) { } @ Override protected void generateLightBrightnessTable ( ) { } @ Override public float [ ] calcSunriseSunsetColors ( float var1 , float var2 ) { } @ Override public void registerWorldChunkManager ( ) { } @ SideOnly ( Side . CLIENT ) @ Override public Vec3 getFogColor ( float var1 , float var2 ) { } @ Override public Vec3 getSkyColor ( Entity cameraEntity , float partialTicks ) { } @ Override @ SideOnly ( Side . CLIENT ) public float getStarBrightness ( float par1 ) { } @ Override public float calculateCelestialAngle ( long par1 , float par3 ) { } public float calculatePhobosAngle ( long par1 , float par3 ) { } public float calculateDeimosAngle ( long par1 , float par3 ) { } @ Override public IChunkProvider createChunkGenerator ( ) { } @ Override public boolean isSkyColored ( ) { } @ Override public double getHorizon ( ) { } @ Override public int getAverageGroundLevel ( ) { } @ Override public boolean isSurfaceWorld ( ) { } @ Override public boolean canCoordinateBeSpawn ( int var1 , int var2 ) { } @ Override public boolean canRespawnHere ( ) { } @ Override public String getSaveFolder ( ) { } @ Override public String getWelcomeMessage ( ) { } @ Override public String getDepartMessage ( ) { } @ Override public String getDimensionName ( ) { } @ Override public boolean canBlockFreeze ( int x , int y , int z , boolean byWater ) { } @ Override public boolean canDoLightning ( Chunk chunk ) { } @ Override public boolean canDoRainSnowIce ( Chunk chunk ) { } @ Override public float getGravity ( ) { } @ Override public int getHeight ( ) { } @ Override public double getMeteorFrequency ( ) { } @ Override public double getFuelUsageMultiplier ( ) { } @ Override public boolean canSpaceshipTierPass ( int tier ) { <START_BUG> return tier >= 4 ; <END_BUG> } @ Override public float getFallDamageModifier ( ) { } @ Override public float getSoundVolReductionAmount ( ) { } @ Override public CelestialBody getCelestialBody ( ) { } @ Override public boolean hasBreathableAtmosphere ( ) { } @ Override public float getThermalLevelModifier ( ) { } @ Override public float getWindLevel ( ) { } }

Fix:
return tier >= 3 ;
Buggy code:
class LightweightDecoratorManager { private HashMap cachedLightweightDecorators = new HashMap ( ) ; private LightweightDecoratorDefinition [ ] lightweightDefinitions ; private static final LightweightDecoratorDefinition [ ] EMPTY_LIGHTWEIGHT_DEF = new LightweightDecoratorDefinition [ 0 ] ; private OverlayCache overlayCache = new OverlayCache ( ) ; LightweightDecoratorManager ( LightweightDecoratorDefinition [ ] definitions ) { } LightweightDecoratorDefinition [ ] getDefinitions ( ) { } LightweightDecoratorDefinition [ ] enabledDefinitions ( ) { } void reset ( ) { } void shutdown ( ) { } LightweightDecoratorDefinition getDecoratorDefinition ( String decoratorId ) { } LightweightDecoratorDefinition [ ] getDecoratorsFor ( Object element ) { } ImageDescriptor [ ] findOverlays ( Object element , Object adapted ) { LightweightDecoratorDefinition [ ] decorators = getDecoratorsFor ( element ) ; <START_BUG> ImageDescriptor [ ] descriptors = new ImageDescriptor [ 4 ] ; <END_BUG> boolean decorated = overlayCache . findDescriptors ( element , decorators , descriptors ) ; if ( adapted != null ) { decorated = decorated || ( overlayCache . findDescriptors ( adapted , getDecoratorsFor ( adapted ) , descriptors ) ) ; } if ( decorated ) return descriptors ; else return null ; } void getPrefixAndSuffix ( Object element , Object adapted , List prefixResult , List suffixResult ) { } OverlayCache getOverlayCache ( ) { } }

Fix:
ImageDescriptor [ ] descriptors = new ImageDescriptor [ 5 ] ;
Buggy code:
public class PreparedQueryImpl implements PreparedQuery { private static Localizer _loc = Localizer . forPackage ( PreparedQueryImpl . class ) ; private final String _id ; private String _sql ; private boolean _initialized ; private Class < ? > _candidate ; private boolean _subclasses ; private QueryExpressions [ ] _exps ; private Class < ? > [ ] _projTypes ; private Map < Object , Integer [ ] > _userParamPositions ; private Map < Integer , Object > _template ; private SelectImpl select ; public PreparedQueryImpl ( String id , Query compiled ) { } public PreparedQueryImpl ( String id , String sql , Query compiled ) { } public String getIdentifier ( ) { } public String getLanguage ( ) { } public String getOriginalQuery ( ) { } public String getTargetQuery ( ) { } void setTargetQuery ( String sql ) { } public boolean isInitialized ( ) { } public QueryExpressions [ ] getQueryExpressions ( ) { } public Class [ ] getProjectionTypes ( ) { } public void setInto ( Query q ) { } public Exclusion initialize ( Object result ) { } private Object [ ] extractSelectExecutor ( Object result ) { } private SelectImpl extractImplementation ( SelectExecutor selector ) { } private boolean isUsingExternalizedParameter ( QueryExpressions exp ) { } private boolean isPaginated ( ) { } private boolean isUsingFieldStrategy ( ) { } private boolean isUsingFieldStrategy ( QueryExpressions exp ) { } public Map < Integer , Object > reparametrize ( Map user , Broker broker ) { } private void setPersistenceCapableParameter ( Map < Integer , Object > result , Object pc , Integer [ ] indices , Broker broker ) { } private void setCollectionValuedParameter ( Map < Integer , Object > result , Collection values , Integer [ ] indices , Object param , Broker broker ) { int n = values . size ( ) ; Object [ ] array = values . toArray ( ) ; <START_BUG> if ( ( n > ( indices . length ) ) || ( ( ( indices . length ) % n ) != 0 ) ) { <END_BUG> throw new org . apache . openjpa . util . UserException ( PreparedQueryImpl . _loc . get ( "uparam-coll-size" , param , values , Arrays . toString ( indices ) ) ) ; } int k = 0 ; for ( int j : indices ) { Object val = array [ ( k % n ) ] ; if ( ImplHelper . isManageable ( val ) ) setPersistenceCapableParameter ( result , val , indices , broker ) ; else result . put ( j , val ) ; k ++ ; } } void setUserParameterPositions ( List list ) { } void setParameters ( List list ) { } SelectImpl getSelect ( ) { } public String toString ( ) { } }

Fix:
if ( ( ( n == 0 ) || ( n > ( indices . length ) ) ) || ( ( ( indices . length ) % n ) != 0 ) ) {
Buggy code:
public class DefaultLogger implements BuildLogger { private static int LEFT_COLUMN_SIZE = 12 ; protected PrintStream out ; protected PrintStream err ; protected int msgOutputLevel = Project . MSG_ERR ; private long startTime = System . currentTimeMillis ( ) ; protected static String lSep = System . getProperty ( "line.separator" ) ; protected boolean emacsMode = false ; public void setMessageOutputLevel ( int level ) { } public void setOutputPrintStream ( PrintStream output ) { } public void setErrorPrintStream ( PrintStream err ) { } public void setEmacsMode ( boolean emacsMode ) { } public void buildStarted ( BuildEvent event ) { } public void buildFinished ( BuildEvent event ) { Throwable error = event . getException ( ) ; if ( error == null ) { out . println ( ( ( DefaultLogger . lSep ) + "BUILD<seq2seq4repair_space>SUCCESSFUL" ) ) ; } else { err . println ( ( ( ( DefaultLogger . lSep ) + "BUILD<seq2seq4repair_space>FAILED" ) + ( DefaultLogger . lSep ) ) ) ; <START_BUG> if ( ( ( Project . MSG_VERBOSE ) <= ( msgOutputLevel ) ) || ( ! ( ( err ) instanceof BuildException ) ) ) { <END_BUG> error . printStackTrace ( err ) ; } else { err . println ( error . getMessage ( ) ) ; } } out . println ( ( ( ( DefaultLogger . lSep ) + "Total<seq2seq4repair_space>time:<seq2seq4repair_space>" ) + ( DefaultLogger . formatTime ( ( ( System . currentTimeMillis ( ) ) - ( startTime ) ) ) ) ) ) ; } public void targetStarted ( BuildEvent event ) { } public void targetFinished ( BuildEvent event ) { } public void taskStarted ( BuildEvent event ) { } public void taskFinished ( BuildEvent event ) { } public void messageLogged ( BuildEvent event ) { } protected static String formatTime ( long millis ) { } }

Fix:
if ( ( ( Project . MSG_VERBOSE ) <= ( msgOutputLevel ) ) || ( ! ( error instanceof BuildException ) ) ) {
Buggy code:
public class PluginDropAdapter extends ViewerDropAdapter { public static final String ATT_CLASS = "class" ; private TransferData currentTransfer ; public PluginDropAdapter ( StructuredViewer viewer ) { } public void drop ( DropTargetEvent event ) { } protected TransferData getCurrentTransfer ( ) { } protected static IDropActionDelegate getPluginAdapter ( PluginTransferData data ) throws CoreException { <START_BUG> IPluginRegistry registry = Platform . getPluginRegistry ( ) ; <END_BUG> String adapterName = data . getExtensionId ( ) ; IExtensionPoint xpt = registry . getExtensionPoint ( PLUGIN_ID , PL_DROP_ACTIONS ) ; IExtension [ ] extensions = xpt . getExtensions ( ) ; for ( int i = 0 ; i < ( extensions . length ) ; i ++ ) { IConfigurationElement [ ] configs = extensions [ i ] . getConfigurationElements ( ) ; if ( ( configs != null ) && ( ( configs . length ) > 0 ) ) { String id = configs [ 0 ] . getAttribute ( "id" ) ; if ( ( id != null ) && ( id . equals ( adapterName ) ) ) { return ( ( IDropActionDelegate ) ( WorkbenchPlugin . createExtension ( configs [ 0 ] , PluginDropAdapter . ATT_CLASS ) ) ) ; } } } return null ; } public boolean performDrop ( Object data ) { } public boolean validateDrop ( Object target , int operation , TransferData transferType ) { } }

Fix:
IExtensionRegistry registry = Platform . getExtensionRegistry ( ) ;
Buggy code:
public abstract class BinaryMember extends NamedMember { protected BinaryMember ( JavaElement parent , String name ) { } public void copy ( IJavaElement container , IJavaElement sibling , String rename , boolean force , IProgressMonitor monitor ) throws JavaModelException { } protected IAnnotation [ ] getAnnotations ( IBinaryAnnotation [ ] binaryAnnotations , long tagBits ) { IAnnotation [ ] standardAnnotations = getStandardAnnotations ( tagBits ) ; if ( binaryAnnotations == null ) return standardAnnotations ; int length = binaryAnnotations . length ; int standardLength = standardAnnotations . length ; IAnnotation [ ] annotations = new IAnnotation [ length + standardLength ] ; for ( int i = 0 ; i < length ; i ++ ) { <START_BUG> annotations [ i ] = Util . getAnnotation ( this , binaryAnnotations [ i ] ) ; <END_BUG> } System . arraycopy ( standardAnnotations , 0 , annotations , length , standardLength ) ; return annotations ; } private IAnnotation getAnnotation ( char [ ] [ ] annotationName ) { } private IAnnotation [ ] getStandardAnnotations ( long tagBits ) { } public String [ ] getCategories ( ) throws JavaModelException { } public String getKey ( ) { } public abstract String getKey ( boolean forceOpen ) throws JavaModelException { } public ISourceRange getNameRange ( ) throws JavaModelException { } public ISourceRange getSourceRange ( ) throws JavaModelException { } public boolean isBinary ( ) { } public boolean isStructureKnown ( ) throws JavaModelException { } public void move ( IJavaElement container , IJavaElement sibling , String rename , boolean force , IProgressMonitor monitor ) throws JavaModelException { } public void rename ( String newName , boolean force , IProgressMonitor monitor ) throws JavaModelException { } public void setContents ( String contents , IProgressMonitor monitor ) throws JavaModelException { } }

Fix:
annotations [ i ] = Util . getAnnotation ( this , binaryAnnotations [ i ] , null ) ;
Buggy code:
@ RunWith ( PowerMockRunner . class ) @ PrepareForTest ( Context . class ) public class ReviewControllerTest { @ Mock ProposedConceptReviewService service ; @ Mock ProposedConceptReviewPackage proposedConceptReviewPackage ; @ Mock ProposedConceptReview proposedConceptReview ; @ InjectMocks ReviewController controller = new ReviewController ( new DescriptionDtoFactory ( ) , new NameDtoFactory ( ) ) ; @ Before public void before ( ) throws Exception { } @ Test public void updateConceptReview_shouldPersistReviewComment ( ) { } @ Test public void getProposalReview_shouldRetrieveProposalReview ( ) { setupProposalMock ( ) ; <START_BUG> ProposedConceptReviewPackageDto proposalDto = controller . getProposalReview ( 1 ) ; <END_BUG> verifyProposalDto ( proposalDto ) ; } @ Test public void getProposalReviews_shouldRetrieveOpenProposalReviews ( ) { } private void setupProposalMock ( ) { } private void verifyProposalDto ( ProposedConceptReviewPackageDto proposalDto ) { } }

Fix:
ProposedConceptReviewPackageDto proposalDto = controller . getProposalReview ( 1 ) . getBody ( ) ;
Buggy code:
public class ModuleInformationServiceProcessor implements DeploymentUnitProcessor { @ Override public void deploy ( final DeploymentPhaseContext phaseContext ) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext . getDeploymentUnit ( ) ; if ( deploymentUnit . hasAttachment ( OSGI_MANIFEST ) ) { return ; } final ModuleSpecification moduleSpec = deploymentUnit . getAttachment ( MODULE_SPECIFICATION ) ; final ModuleIdentifier moduleIdentifier = deploymentUnit . getAttachment ( MODULE_IDENTIFIER ) ; final List < AdditionalModuleSpecification > additionalModules = deploymentUnit . getAttachmentList ( ADDITIONAL_MODULES ) ; if ( ( moduleIdentifier == null ) || ( moduleSpec == null ) ) { return ; } phaseContext . getServiceTarget ( ) . addService ( ServiceModuleLoader . moduleInformationServiceName ( moduleIdentifier ) , new org . jboss . msc . service . ValueService < Object > ( new org . jboss . msc . value . ImmediateValue < Object > ( moduleSpec ) ) ) . install ( ) ; <START_BUG> for ( ModuleDependency dependency : moduleSpec . getSystemDependencies ( ) ) { <END_BUG> if ( dependency . getIdentifier ( ) . getName ( ) . startsWith ( MODULE_PREFIX ) ) { phaseContext . addDependency ( ServiceModuleLoader . moduleInformationServiceName ( dependency . getIdentifier ( ) ) , MODULE_DEPENDENCY_INFORMATION ) ; } } for ( AdditionalModuleSpecification module : additionalModules ) { phaseContext . getServiceTarget ( ) . addService ( ServiceModuleLoader . moduleInformationServiceName ( module . getModuleIdentifier ( ) ) , new org . jboss . msc . service . ValueService < Object > ( new org . jboss . msc . value . ImmediateValue < Object > ( module ) ) ) . install ( ) ; } } @ Override public void undeploy ( final DeploymentUnit context ) { } }

Fix:
for ( ModuleDependency dependency : moduleSpec . getAllDependencies ( ) ) {