mil.dod.th.ose.core.integration/src/mil/dod/th/ose/core/integration/TestMissionProgramming.java
public void testTriggeredDataCapture_Metadata()
    {
        MissionProgramTemplate template = m_TemplateProgramManager.getTemplate("triggered-data-captured");
        List<String> missionModalityTypes = 
                Maps.uniqueIndex(template.getVariableMetaData(), new Function<MissionVariableMetaData, String>()
                {
        
                    @Override
                    public String apply(MissionVariableMetaData metaData)
                    {
                        return metaData.getName();
                    }
                }).get("modalityType").getOptionValues();
        
        List<String> enumValues = new ArrayList<>(
                Lists.transform(Arrays.asList(SensingModalityEnum.values()), new Function<SensingModalityEnum, String>()
                {
                    @Override
                    public String apply(SensingModalityEnum enumValue)
                    {
                        return enumValue.value();
                    }
                }));
        // should match except metadata should have Any value in addition, but not Unknown
        enumValues.add("Any");
        enumValues.remove(SensingModalityEnum.UNKNOWN.value());
        
        assertThat(new HashSet<>(missionModalityTypes), is(new HashSet<>(enumValues)));
    }
/**
     * Verify metadata enum list has all the enum values defined in {@link SensingModalityEnum}.
     */
Verify metadata enum list has all the enum values defined in  SensingModalityEnum.
Verify metadata enum list has all the enum values defined in SensingModalityEnum .
public void testTriggeredDataCapture_Metadata()
    {
        MissionProgramTemplate template = m_TemplateProgramManager.getTemplate("triggered-data-captured");
        List<String> missionModalityTypes = 
                Maps.uniqueIndex(template.getVariableMetaData(), new Function<MissionVariableMetaData, String>()
                {
                    @Override
                    public String apply(MissionVariableMetaData metaData)
                    {
                        return metaData.getName();
                    }
                }).get("modalityType").getOptionValues();
        List<String> enumValues = new ArrayList<>(
                Lists.transform(Arrays.asList(SensingModalityEnum.values()), new Function<SensingModalityEnum, String>()
                {
                    @Override
                    public String apply(SensingModalityEnum enumValue)
                    {
                        return enumValue.value();
                    }
                }));
        enumValues.add("Any");
        enumValues.remove(SensingModalityEnum.UNKNOWN.value());
        assertThat(new HashSet<>(missionModalityTypes), is(new HashSet<>(enumValues)));
    }
public void testTriggeredDataCapture_Metadata ( ) { MissionProgramTemplate template = m_TemplateProgramManager . getTemplate ( "triggered-data-captured" ) ; List < String > missionModalityTypes = Maps . uniqueIndex ( template . getVariableMetaData ( ) , new Function < MissionVariableMetaData , String > ( ) { @ Override public String apply ( MissionVariableMetaData metaData ) { return metaData . getName ( ) ; } } ) . get ( "modalityType" ) . getOptionValues ( ) ; List < String > enumValues = new ArrayList < > ( Lists . transform ( Arrays . asList ( SensingModalityEnum . values ( ) ) , new Function < SensingModalityEnum , String > ( ) { @ Override public String apply ( SensingModalityEnum enumValue ) { return enumValue . value ( ) ; } } ) ) ; enumValues . add ( "Any" ) ; enumValues . remove ( SensingModalityEnum . UNKNOWN . value ( ) ) ; assertThat ( new HashSet < > ( missionModalityTypes ) , is ( new HashSet < > ( enumValues ) ) ) ; }
Verify metadata enum list has all the enum values defined in {@link SensingModalityEnum}.
Verify metadata enum list has all the enum values defined in { @link SensingModalityEnum } .
// should match except metadata should have Any value in addition, but not Unknown