mil.dod.th.ose.lexicon.doc/test/mil/dod/th/ose/lexicon/doc/main/TestLexiconDocGeneratorMain.java
@SuppressWarnings("unchecked")
    @Test
    public void testProcessCommandLine() throws ParserConfigurationException, SAXException, IOException
    {
        final List<LexiconBase> types = new ArrayList<>();
        
        when(m_FileService.getFile("output")).thenReturn(m_OutputFile);
        when(m_FileService.getFile("xsdDir")).thenReturn(m_XsdDir);
        
        when(m_XsdDir.exists()).thenReturn(true);
        when(m_XsdDir.isDirectory()).thenReturn(true);
        
        when(m_LexiconParser.parserXsdFiles(Mockito.anyList(), Mockito.any(DocumentBuilder.class))).thenReturn(types);
        
        final String[] args = new String[]{ "output", "xsdDir"};
        m_SUT.processCommandLine(m_PrintStream, args);
        
        verify(m_LexiconParser).parserXsdFiles(Mockito.anyList(), Mockito.any(DocumentBuilder.class));
        verify(m_MarkupGen).generateMarkup(m_OutputFile, types);
    }
/**
     * Verify that the appropriate calls are made based off the arguments passed.
     */
Verify that the appropriate calls are made based off the arguments passed.
Verify that the appropriate calls are made based off the arguments passed .
@SuppressWarnings("unchecked")
    @Test
    public void testProcessCommandLine() throws ParserConfigurationException, SAXException, IOException
    {
        final List<LexiconBase> types = new ArrayList<>();
        when(m_FileService.getFile("output")).thenReturn(m_OutputFile);
        when(m_FileService.getFile("xsdDir")).thenReturn(m_XsdDir);
        when(m_XsdDir.exists()).thenReturn(true);
        when(m_XsdDir.isDirectory()).thenReturn(true);
        when(m_LexiconParser.parserXsdFiles(Mockito.anyList(), Mockito.any(DocumentBuilder.class))).thenReturn(types);
        final String[] args = new String[]{ "output", "xsdDir"};
        m_SUT.processCommandLine(m_PrintStream, args);
        verify(m_LexiconParser).parserXsdFiles(Mockito.anyList(), Mockito.any(DocumentBuilder.class));
        verify(m_MarkupGen).generateMarkup(m_OutputFile, types);
    }
@ SuppressWarnings ( "unchecked" ) @ Test public void testProcessCommandLine ( ) throws ParserConfigurationException , SAXException , IOException { final List < LexiconBase > types = new ArrayList < > ( ) ; when ( m_FileService . getFile ( "output" ) ) . thenReturn ( m_OutputFile ) ; when ( m_FileService . getFile ( "xsdDir" ) ) . thenReturn ( m_XsdDir ) ; when ( m_XsdDir . exists ( ) ) . thenReturn ( true ) ; when ( m_XsdDir . isDirectory ( ) ) . thenReturn ( true ) ; when ( m_LexiconParser . parserXsdFiles ( Mockito . anyList ( ) , Mockito . any ( DocumentBuilder . class ) ) ) . thenReturn ( types ) ; final String [ ] args = new String [ ] { "output" , "xsdDir" } ; m_SUT . processCommandLine ( m_PrintStream , args ) ; verify ( m_LexiconParser ) . parserXsdFiles ( Mockito . anyList ( ) , Mockito . any ( DocumentBuilder . class ) ) ; verify ( m_MarkupGen ) . generateMarkup ( m_OutputFile , types ) ; }
Verify that the appropriate calls are made based off the arguments passed.
Verify that the appropriate calls are made based off the arguments passed .