mil.dod.th.ose.gui.webapp/test/mil/dod/th/ose/gui/webapp/comms/TestCommsLayerLinkModel.java
@Test
    public void testIsComplete()
    {
        assertThat(m_SUT.isComplete(), is(false));
        m_SUT.setActivated(true);
        assertThat(m_SUT.isComplete(), is(false));
        m_SUT.setStatus(LinkStatus.OK);
        assertThat(m_SUT.isComplete(), is(false));
        
        LinkLayerCapabilities caps = mock(LinkLayerCapabilities.class);
        when(m_TypesMgr.getCapabilities(123, "clazz")).thenReturn(caps);
        
        m_SUT.updateName("newName");
        assertThat(m_SUT.getName(), is("newName"));
        
        assertThat(m_SUT.isComplete(), is(true));
    }
/**
     * Verify the isComplete method returns true when all information for the link layer is available
     */
Verify the isComplete method returns true when all information for the link layer is available
Verify the isComplete method returns true when all information for the link layer is available
@Test
    public void testIsComplete()
    {
        assertThat(m_SUT.isComplete(), is(false));
        m_SUT.setActivated(true);
        assertThat(m_SUT.isComplete(), is(false));
        m_SUT.setStatus(LinkStatus.OK);
        assertThat(m_SUT.isComplete(), is(false));
        LinkLayerCapabilities caps = mock(LinkLayerCapabilities.class);
        when(m_TypesMgr.getCapabilities(123, "clazz")).thenReturn(caps);
        m_SUT.updateName("newName");
        assertThat(m_SUT.getName(), is("newName"));
        assertThat(m_SUT.isComplete(), is(true));
    }
@ Test public void testIsComplete ( ) { assertThat ( m_SUT . isComplete ( ) , is ( false ) ) ; m_SUT . setActivated ( true ) ; assertThat ( m_SUT . isComplete ( ) , is ( false ) ) ; m_SUT . setStatus ( LinkStatus . OK ) ; assertThat ( m_SUT . isComplete ( ) , is ( false ) ) ; LinkLayerCapabilities caps = mock ( LinkLayerCapabilities . class ) ; when ( m_TypesMgr . getCapabilities ( 123 , "clazz" ) ) . thenReturn ( caps ) ; m_SUT . updateName ( "newName" ) ; assertThat ( m_SUT . getName ( ) , is ( "newName" ) ) ; assertThat ( m_SUT . isComplete ( ) , is ( true ) ) ; }
Verify the isComplete method returns true when all information for the link layer is available
Verify the isComplete method returns true when all information for the link layer is available